Lädt...


🔧 Netlify Dynamic Site Challenge : Building blob playground with Netlify Blob


Nachrichtenbereich: 🔧 Programmierung
🔗 Quelle: dev.to

This is a submission for the Netlify Dynamic Site Challenge: Build with Blobs.

What I Built

I implemented a file upload feature in an Angular application, allowing users to store files in Netlify Blobs storage. Users can upload files, which are then stored in the Netlify Blobs store. Additionally, I integrated Netlify Functions to handle processing tasks, enabling efficient retrieval and management of blob objects, including metadata handling.

Demo

Image description

Platform Primitives

  1. Angular Application: I've created an Angular application as the front end for interacting with the Netlify Blobs.

  2. File Upload Feature: Users can upload files through the Angular application's interface. This involves creating a form with a file input field and handling the file submission in the Angular component.

  3. Netlify Blob Storage Integration: I've integrated Netlify Blobs into the Angular application. This includes setting up the necessary configurations to interact with the Netlify Blobs API provided by Netlify. To use the Netlify Blobs API, first install the @netlify/blobs module using the

npm install @netlify/blobs
  1. Storing Files as Blobs: Upon file upload, the Angular application converts the file into an object and sets it into the Netlify Blobs. This involves making API requests to Netlify Blob storage endpoints. First we will get store after that we will setJson into it.
 const mystore = getStore("your-store-name");
 await mystore.setJSON("file-1", { type: "file", filesize: "10kb" });
  1. Retrieving Files: Users can retrieve files stored in the Netlify Blobs through your Angular application. This involves making API requests to fetch Blob objects from Netlify Blobs and rendering them appropriately in the application interface.
 const mystore = getStore("your-store-name");
 const entry1 = await my store.get("file-1");
 console.log(entry1) //you will get the above setjson value
  1. Metadata Handling: The application handles metadata associated with the uploaded files. This might include storing additional information like file name, file size, upload timestamp, etc., along with the Blob object in the storage.
//set(key, value, { metadata? })

const mystore = getStore("your-store-name");
 await mystore.setJSON("file-1", { type: "file", fileData: "xyz" }, {metadata: { name: "font.png", type: "image/png", size: "1.2 KiB" });
  1. Integration with Netlify Functions: I've integrated Netlify Functions into project for processing tasks related to Blobs. This could include tasks like file manipulation, set metadata, or any other custom operations you need to perform on the Blobs.
npm install @netlify/functions
import type { Context } from "@netlify/functions"

export default async (req: Request, context: Context) => {
  return new Response("Hello, world!")
}

Netlify Image CDN submission URL => Visit Here

...

🔧 Netlify Dynamic Site Challenge : Building blob playground with Netlify Blob


📈 105.03 Punkte
🔧 Programmierung

🔧 Netlify Dynamic Site Challenge : Building a Dynamic Image Gallery with Netlify Image CDN


📈 70.31 Punkte
🔧 Programmierung

🔧 Netlify Dynamic Site Challenge: Web Voyager, a website screenshot service using Netlify Blob storage.


📈 66.81 Punkte
🔧 Programmierung

🔧 Netlify Dynamic Site Challenge Submission: Dynamic Image Gallery with Netlify Image CDN Visual Feast


📈 63.24 Punkte
🔧 Programmierung

🔧 Netlify Dynamic Site Challenge Submission: Dynamic Image Gallery with Netlify Image CDN Visual Feast


📈 63.24 Punkte
🔧 Programmierung

🔧 Netlify Dynamic Site Challenge : Building News Article Cache Management playground


📈 61.91 Punkte
🔧 Programmierung

🔧 Netlify Dynamic Site Challenge : Building a Dynamic Image Gallery


📈 54.97 Punkte
🔧 Programmierung

🔧 Netlify Dynamic Site Challenge: Photo Gallery with React and Netlify Image CDN


📈 52.92 Punkte
🔧 Programmierung

🔧 Page Views Counter: Netlify Dynamic Site Challenge using Netlify Blobs


📈 52.92 Punkte
🔧 Programmierung

🔧 Netlify Dynamic Site Challenge - Netlify Image CDN to transform an image Gallery


📈 52.92 Punkte
🔧 Programmierung

🔧 Netlify Dynamic Site Challenge - Netlify Image CDN to transform an image Gallery


📈 52.92 Punkte
🔧 Programmierung

🔧 Netlify Dynamic Site Challenge - Netlify Image CDN to transform an image Gallery


📈 52.92 Punkte
🔧 Programmierung

🔧 Netlify Dynamic Site Challenge Submission: Visual Feast-- Netlify CDN Cache-Control Implementation


📈 52.92 Punkte
🔧 Programmierung

🔧 Let’s Get Dynamic! Ideas for the Netlify Dynamic Site Challenge


📈 47.91 Punkte
🔧 Programmierung

🔧 Netlify Dynamic Site Challenge: Building a Mars Mission Photo Web App


📈 44.65 Punkte
🔧 Programmierung

🔧 Netlify Dynamic Site Challenge: Building a Device Mockups Generator Web App


📈 44.65 Punkte
🔧 Programmierung

🔧 Netlify Dynamic Site Challenge: Building a Mars Mission Photo Web App


📈 44.65 Punkte
🔧 Programmierung

🕵️ CVE-2019-2231 | Google Android 9.0/10.0 blob.cpp Blob::Blob input validation


📈 41.66 Punkte
🕵️ Sicherheitslücken

🔧 Fast Storage - Netlify Blob challenge


📈 38.33 Punkte
🔧 Programmierung

🔧 Join us for the Netlify Dynamic Site Challenge: $3,000 in Prizes!


📈 37.58 Punkte
🔧 Programmierung

🔧 Congrats to the Netlify Dynamic Site Challenge Winners!


📈 37.58 Punkte
🔧 Programmierung

🔧 Netlify Dynamic Site Challenge: Make Your Favorite Image Collection 🎆


📈 37.58 Punkte
🔧 Programmierung

🔧 Netlify Dynamic Site Challenge : Using the power of CDNs and Transformations for a visual feast


📈 37.58 Punkte
🔧 Programmierung

🔧 Netlify Dynamic Site Challenge: Motizen, a treasure hunt game


📈 37.58 Punkte
🔧 Programmierung

🔧 Netlify Dynamic Site Challenge: Mini Gallery


📈 37.58 Punkte
🔧 Programmierung

🔧 🏆 Pick Your Champion - Netlify Dynamic Site Challenge


📈 37.58 Punkte
🔧 Programmierung

🔧 🎨 Logo Hunter - Netlify Dynamic Site Challenge


📈 37.58 Punkte
🔧 Programmierung

🔧 Network Topologies- Netlify Dynamic Site Challenge


📈 37.58 Punkte
🔧 Programmierung

🔧 Dev OPinion - Netlify Dynamic Site Challenge Submission


📈 37.58 Punkte
🔧 Programmierung

🔧 Netlify Dynamic Site Challenge - Help Thread!


📈 37.58 Punkte
🔧 Programmierung

🕵️ CGit bis 0.11 ui-blob Handler blob/cgit.c mimetype Cross Site Scripting


📈 30.59 Punkte
🕵️ Sicherheitslücken

🕵️ CGit bis 0.11 ui-blob Handler blob/cgit.c mimetype Cross Site Scripting


📈 30.59 Punkte
🕵️ Sicherheitslücken

🔧 ImageGround: Netlify Dynamic Image CDN Site


📈 28.48 Punkte
🔧 Programmierung

🔧 Trabalhando com o Azure Blob Storage ("Synapse"), para leitura de arquivos em um blob


📈 27.78 Punkte
🔧 Programmierung

matomo