Supabase Edge Functions Quickstart
Описание
We’re back with another Supabase tutorial - we're talking Edge Functions, showcasing how they make your project much more functional.
Edge Functions are server-side TypeScript functions, distributed globally at the edge—close to your users. They can be used for listening to webhooks or integrating your Supabase project with third-parties like Stripe. Edge Functions are developed using Deno.
- Read the docs: https://supabase.com/docs/guides/functions/quickstart
- Install and update the Supabase CLI: https://supabase.com/docs/guides/cli/getting-started#installing-the-supabase-cli
- List of preset environment variables: https://supabase.com/docs/guides/functions/secrets#default-secrets
This video covers everything from setting up your environment with the most recent Supabase CLI to configuring VS Code for Deno development and will teach you to create server-side TypeScript functions that operate at the edge, optimizing performance for your users.
We'll walk you through importing npm packages directly into your functions, setting up a Supabase-js client, and utilizing preset environment variables to make development much easier.
What you'll learn:
✅ VS Code and Deno Configuration: Get your VS Code ready for Deno with recommended settings and extensions, tailored for Supabase Edge Functions.
✅ How to Create Edge Functions in Supabase: Step-by-step guide to creating your first Edge Function, ready to integrate with services like Stripe or handle webhooks.
✅ Importing npm Packages: Learn the convenience of importing npm packages directly, expanding your function's capabilities.
✅ Supabase-js Client and Environment Variables: Establish a Supabase-js client within your function and leverage preset environment variables for efficient and secure development.
After watching this video, you'll be able to:
✅ Develop and Deploy Edge Functions: Confidently develop and deploy Edge Functions in your Supabase project.
✅ Manage Environment Secrets: Set and managing environment secrets within Supabase, safeguarding your project's sensitive data and ensuring compliance.
Watch the full edge functions tutorial playlist HERE: https://www.youtube.com/watch?v=uZ6R9p3mgWM&list=PL5S4mPUpp4OulD3olUW8Eq1IYKpUbk5Ob
Presented by Thor Schaeff (@thorwebdev https://go.thor.bio/x)
Chapters:
00:00 Supabase Edge Functions Quickstart
00:20 Generate VScode settings for Deno
00:58 Install the Deno Language Server extension for VScode
02:05 Import packages from npm
03:05 Create a supabase-js client
03:18 Use the preset environment variables
05:34 Set environment secrets
06:06 Create a new project at database.new
07:22 Link your Supabase project
07:52 Serve Edge Functions locally
09:00 Inspect the local Supabase Studio
09:40 Managing Row Level Security policies
11:20 Deploy the Edge Function to Supabase
11:42 Inspect the Edge Function in the Supabase Dashboard
---
Learn more about Supabase 👇
🕸 Website: https://supabase.com/
🏁 Get started: https://app.supabase.com/
📄 Docs: https://supabase.com/docs
💻 Videos to watch next:
▶ Watch more Edge functions with Supabase: https://www.youtube.com/watch?v=uZ6R9p3mgWM&list=PL5S4mPUpp4OulD3olUW8Eq1IYKpUbk5Ob
▶ How to handle signed Stripe Webhooks with Edge functions: https://youtu.be/6OMVWiiycLs?feature=shared
▶ How Deploy Edge Functions with GitHub Actions: https://www.youtube.com/watch?v=l2KlzGrhB6w&list=PL5S4mPUpp4OulD3olUW8Eq1IYKpUbk5Ob&index=5
🔔 Subscribe for more tutorials and feature updates from Supabase: https://www.youtube.com/channel/UCNTVzV1InxHV-YR0fSajqPQ?sub_confirmation=1
📱 Connect with Us:
🐙 Github: https://www.github.com/supabase
💬 Discord: https://www.discord.supabase.com/
🐦 Twitter: https://www.twitter.com/supabase/
▶ Instagram (follow for memes): https://www.instagram.com/supabasecom/
ABOUT SUPABASE:
Supabase is the open source Firebase alternative. Supabase provides a full Postgres database for every project with pgvector, backups, realtime, and more. Add and manage email and password, passwordless, OAuth, and mobile logins to your project through a suite of identity providers and APIs.
Build in a weekend, scale to millions.
#Supabase #AppDevelopment #RealtimeApps #DeveloperTools
Рекомендуемые видео



















