The Postgres development platform. Supabase gives you a dedicated Postgres database to build your web, mobile, and AI applications.
TypeScript aialternativeauthdatabasedenoembeddingsexamplefirebasenextjsoauth2pgvectorpostgispostgrespostgresqlpostgrestrealtimesupabasevectorswebsockets
Blog post draft
Terry Sutton558e73ac983f
diff --git a/apps/www/_blog/2023-04-14-supabase-studio-2.0.mdx b/apps/www/_blog/2023-04-14-supabase-studio-2.0.mdxindex e0aee9224c3..b0df758df51 100644--- a/apps/www/_blog/2023-04-14-supabase-studio-2.0.mdx+++ b/apps/www/_blog/2023-04-14-supabase-studio-2.0.mdx@@ -6,68 +6,165 @@ tags:- studiodate: '2023-04-14'to_depth: 3-author: alaister,joshenlim+author: alaister,joshenlim,saltcodimage: launch-week-7/day-5-supabase-studio-2.0/day-5-supabase-studio-2.0-og.jpgthumb: launch-week-7/day-5-supabase-studio-2.0/day-5-supabase-studio-2.0-thumb.jpg----Today, we're releasing Supabase Logs for both self-hosted users and CLI development.--Nullam a magna ante. Orci varius natoque penatibus et magnis dis parturient montes, nascetur ridiculus mus. Donec fermentum nisi erat, et convallis magna accumsan id. Integer vehicula elit id accumsan rhoncus. Ut non turpis lacinia, ultrices enim ac, tincidunt sem. Sed semper lectus nec quam porta molestie.--<ImageFadeStack- images={[- 'https://supabase.com/_next/image?url=%2Fimages%2Fblog%2Flaunch-week-7%2Fday-3-storage-resumable-uploads%2Fstorage-v3-thumb.jpg&w=2048&q=75',- 'https://obuldanrptloktxcffvn.supabase.co/storage/v1/object/public/images/lw7/tickets_bg/reg_bg_10.png',- 'https://obuldanrptloktxcffvn.supabase.co/storage/v1/object/public/images/lw7/tickets_bg/reg_bg_11.png',- ]}- delay={3000}-/>+Today we're announcing Supabase Studio 2.0, packed with a ton of new stuff. We have features people have been asking for forever, and new capabilities that will change the way you work.++Here's the birds-eye-view:++<ul>+ <li>[**⌘K Menu with AI**](#k-menu-with-ai): ChatGPT, right in the Studio</li>+ <li>[**GraphiQL**](#item-one): Query your database with GraphQL</li>+ <li>[**Cascade deletes**](#item-one): Our #1 most requested feature from the community</li>+ <li>[**Query Performance**](#item-one): Investiate slow running queries</li>+ <li>[**Foreign key Selector**](#item-one): Lookup a referencing row in another table</li>+ <li>[**Postgres Roles**](#item-one): Manage your Postgres roles and privileges</li>+ <li>[**Database Webhooks**](#item-one): Update webhooks and select Edge Functions</li>+ <li>[**Network restrictions**](#item-one): Block access from specified IP ranges</li>+ <li>[**Table/View definitions**](#item-one): View SQL definitions for tables and views</li>+ <li>[**API Autodocs**](#item-one): Auto-generated docs, right in the Table Editor</li>+ <li>[**Support for many tables**](#item-one): Editor support for thousands of tables</li>+ <li>[**JSON editing**](#item-one): Improved JSON editing</li>+ <li>[**Nullable columns**](#item-one): Allow text/bool cells to be null or empty</li>+</ul><div className="video-container"><iframeclassName="w-full"- width="560"- height="315"- src="https://www.youtube.com/embed/Ai2BjHV36Ng"+ src="https://www.youtube-nocookie.com/embed/cPGxPl1lx4Y"title="YouTube video player"frameborder="0"allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share"allowfullscreen></iframe>- _Whatch the video announcement_</div>-## Introduction+## ⌘K Menu with AI-Lorem ipsum dolor sit amet, consectetur adipiscing elit. Sed commodo quam neque, ut volutpat quam ultrices ut. Fusce aliquet porta fermentum. Ut ultricies bibendum justo, vel sagittis sem porta ac.+<ImageFadeStack+ autoplay+ showNavigation+ altText="Studio cmdk menu"+ delay={3000}+ images={[+ '/images/blog/lw7-studio/cmdk-1.png',+ '/images/blog/lw7-studio/cmdk-2.png',+ '/images/blog/lw7-studio/cmdk-3.png',+ '/images/blog/lw7-studio/cmdk-4.png',+ '/images/blog/lw7-studio/cmdk-5.png',+ ]}+/>-Nullam a magna ante. Orci varius natoque penatibus et magnis dis parturient montes, nascetur ridiculus mus. Donec fermentum nisi erat, et convallis magna accumsan id. Integer vehicula elit id accumsan rhoncus. Ut non turpis lacinia, ultrices enim ac, tincidunt sem. Sed semper lectus nec quam porta molestie.+One of our guiding principles at Supabase is to to make SQL more accessible to developers. We don't want to just abstract it away with a custom implementation. By embracing SQL, developers learn important, transferrable skills while they build on top of Supabase.-- **[item one](#item-one)** — item one description-- **[item two](#item-two)** — item two description-- **[item three](#item-three)** — item three description+In the past few months, AI advancements have made this easy! Writing a complex SQL query is now as simple as asking ChatGPT, and we're leaning into this approach with our Studio. AI gives developers superpowers, and by providing relevant context, Supabase gives AI superpowers.-## Item one+AI has already changed a lot about the way we work as developers. We can use ChatGPT to write code for us as fast as we cant prompt it. We wanted to bring this power into the Studio with integrations that will help you work even faster than before.-Lorem ipsum dolor sit amet, consectetur adipiscing elit. Sed commodo quam neque, ut volutpat quam ultrices ut. Fusce aliquet porta fermentum. Ut ultricies bibendum justo, vel sagittis sem porta ac.+Today you'll be able to do many common SQL operations with the help of AI. You can create tables, views and indexes, write functions and triggers, and more, right from the ⌘K menu.-## Item two+Soon, we'll also let you opt-in to sending your table schemas to OpenAI to help fine tune queries to your project. All this should result in a dramatic boost in development speed. Maybe you'll only need half a weekend to scale to millions now!-Lorem ipsum dolor sit amet, consectetur adipiscing elit. Sed commodo quam neque, ut volutpat quam ultrices ut. Fusce aliquet porta fermentum. Ut ultricies bibendum justo, vel sagittis sem porta ac.+As with every ⌘K menu, quick navigation is at the heart of things. You'll now be able to jump to any page in the Studio in a couple of keystrokes. You can also search the Docs directly from the menu.-## Item three+We'll be actively working on our ⌘K menu in the coming months to make it faster and even more useful for you. We're going to focus next on better support for writing RLS policies. Stay tuned!-Lorem ipsum dolor sit amet, consectetur adipiscing elit. Sed commodo quam neque, ut volutpat quam ultrices ut. Fusce aliquet porta fermentum. Ut ultricies bibendum justo, vel sagittis sem porta ac.+## New features-+Along with the new AI features, we also doubled-down on some of the critical missing pieces for a Postgres UI. Before we started to work on any of these, we combed through user feedback and tallied up the most submitted Feature Requests on Github.<div className="bg-gray-300 rounded-lg px-6 py-2 italic">-📢 Check out the [lorem ipsum](https://supabase.com/docs/reference/self-hosting-analytics/introduction) to learn more.+📢 Many of the features and enhancements below came from user requests — [please keep them coming](https://github.com/orgs/supabase/discussions/categories/feature-requests)!</div>+### GraphiQL++++While GraphQL has been available in Supabase for just over a year, we haven't provided a visual tool for using it. You can now use the very popular GraphiQL directly from the Studio. GraphiQL is a browser tool for writing, validating, and testing GraphQL testing. Being able to use a fully integrated GraphQL IDE is a huge DX win.++### Cascade deletes++++Cascade deletes are a core feature of Postgres, but have not been available in the Studio UI until now. This has been the #1 feature request from the community for a long time. You can now choose what you want to happen when deleting a referenced row in another table, right from Table Editor side panel.++### Query Performance++++We've just released a new Query Performance tool to help you identify slow queries. Using this tool, along with our new [guide](https://supabase.com/docs/guides/platform/performance#examining-query-performance) should help you speed things up. These tools can help you uncover where you might have inefficient queries or schemas, or where you might need indexes or even additional compute resources.++### Foreign key selector++<ImageFadeStack+ autoplay+ showNavigation+ altText="Studio cmdk menu"+ delay={4000}+ images={[+ '/images/blog/lw7-studio/foreign-table-lookup-1.png',+ '/images/blog/lw7-studio/foreign-table-lookup-2.png',+ '/images/blog/lw7-studio/foreign-table-lookup-3.png',+ '/images/blog/lw7-studio/foreign-table-lookup-4.png',+ '/images/blog/lw7-studio/foreign-table-lookup-5.png',+ '/images/blog/lw7-studio/foreign-table-lookup-6.png',+ '/images/blog/lw7-studio/foreign-table-lookup-7.png',+ ]}+/>+You can now select a referencing row from another table, rather than having to pass a value manually.+You can also quickly jump to the row being referenced in another table with the _View referencing_ record+button from the grid itself.++### Postgres Roles++++The Roles page got a huge revision, making it easy for you to manage access control through users, groups, and permissions. It's now easy to see how many connections you're using and where they're coming from.++### Database Webhooks++++We've wanted to improve the webhooks interface for a long time, and we've finally gotten to it. We now have full support for editing your webhooks, and you can now select an edge function to call instead of having to pass in a url. We're happy to roll this very common request out to the community.++### Network restrictions++[need a screenshot]++A new add-on for you to configure restrictions on the IP ranges that are allowed to connect to your Postgres database. With network restrictions, you're able to control exactly who has access to your data. Read more in the Docs.++### Table/View definitions++++You can now see the SQL definitions for your tables and views, directly from the Table Editor. This is a great way to see how Supabase is translating your UI changes into SQL. This can be useful for creating migrations, getting help, or just for learning more about how Supabase and SQL works.++### API Autodocs++++You can now view the auto-generated API docs right from the Table Editor. Grab the SQL and `supabase-js` code for all of the CRUD operations, straight from the table. You can also quickly generate and download a Typescript types file for your table, right from the editor.++### Quality of life improvements++#### Support for many tables++Previously, the Table Editor would get slow and unresponsive when you had many tables. We've made a number of improvements to make it much faster and more responsive. Feel free to make all the tables you need!++#### JSON editing++You've always been able to use the JSON data type in your tables, but editing the data wasn't easy. We've improved the inline table editor, and also now allow you open json cells from the side panel for a more spacious editing experience. Next Launch Week we're hoping to decide if it's pronounced “Jason” or “Jay-sawn”. Stay tuned.++#### Nullable columns++Speaking of extremely common feature requests, we've gotten this one a lot in the past few months. You used to have to handle this manually, but now you can now allow text/boolean cells to be null or empty. Supabase, where productivity is more than just an empty (or null) promise.+## Wrapping Up-Lorem ipsum dolor sit amet, consectetur adipiscing elit. Sed commodo quam neque, ut volutpat quam ultrices ut. Fusce aliquet porta fermentum. Ut ultricies bibendum justo, vel sagittis sem porta ac.+We hope you get a lot of value out of these new features and enhancements. As we mentioned earlier, many of the features listed here came directly from [Feature Requests](https://github.com/orgs/supabase/discussions/categories/feature-requests) on Github. Thanks to everyone who have taken the time to submit these, and encourage submissions for anything else you'd like to see.diff --git a/apps/www/components/ImageFadeStack.tsx b/apps/www/components/ImageFadeStack.tsxindex 3077a7e0fb0..311e443f15d 100644--- a/apps/www/components/ImageFadeStack.tsx+++ b/apps/www/components/ImageFadeStack.tsx@@ -1,17 +1,27 @@import Image from 'next/image'import React, { useState, useEffect } from 'react'-import { IconCircle, IconDroplet, IconPauseCircle, IconPlayCircle } from 'ui'+import { IconPauseCircle, IconPlayCircle } from 'ui'import { cn } from '~/../../packages/ui/src/utils/cn'interface ImageFadeStackProps {+ autoplay?: booleanimages: string[]height?: 'default'delay?: number+ altText?: string+ showNavigation?: boolean}-const ImageFadeStack = ({ images, height = 'default', delay = 3000 }: ImageFadeStackProps) => {+const ImageFadeStack = ({+ images,+ height = 'default',+ delay = 3000,+ autoplay = false,+ altText = 'Image',+ showNavigation = false,+}: ImageFadeStackProps) => {const [currentImageIndex, setCurrentImageIndex] = useState(0)- const [isPlaying, setIsPlaying] = useState(true)+ const [isPlaying, setIsPlaying] = useState(autoplay)useEffect(() => {if (isPlaying) {@@ -29,7 +39,7 @@ const ImageFadeStack = ({ images, height = 'default', delay = 3000 }: ImageFadeS}return (- <div className={`relative ${height === 'default' ? 'min-h-[320px]' : 'min-h-[400px]'} my-12`}>+ <div className={`relative ${height === 'default' ? 'h-[320px]' : 'h-[400px]'} my-12`}>{images.map((image, index) => (<><Image@@ -37,7 +47,7 @@ const ImageFadeStack = ({ images, height = 'default', delay = 3000 }: ImageFadeSkey={index}src={image}layout="fill"- alt={`Image ${index + 1}`}+ alt={altText}style={{opacity: currentImageIndex === index ? 1 : 0,transition: 'opacity 1s ease-in-out',@@ -46,16 +56,17 @@ const ImageFadeStack = ({ images, height = 'default', delay = 3000 }: ImageFadeS</>))}<div className="absolute bottom-4 right-4 flex gap-3">- {images.map((_, index) => (- <button className="text-white" onClick={() => handleNavClick(index)}>- <div- className={cn(- 'w-2 h-2 rounded-full bg-scale-900 hover:bg-gray-300 transition-colors',- currentImageIndex === index && 'bg-scale-700'- )}- />- </button>- ))}+ {showNavigation &&+ images.map((_, index) => (+ <button className="text-white" onClick={() => handleNavClick(index)}>+ <div+ className={cn(+ 'w-2 h-2 rounded-full bg-scale-900 hover:bg-gray-300 transition-colors',+ currentImageIndex === index && 'bg-scale-700'+ )}+ />+ </button>+ ))}<buttononClick={() => setIsPlaying(!isPlaying)}className="text-white bg-scale-1100 hover:bg-gray-1100 dark:hover:bg-gray-500 rounded-full p-0.5 transition-colors"diff --git a/apps/www/lib/authors.json b/apps/www/lib/authors.jsonindex 682ed8fca68..b255e4bfcb5 100644--- a/apps/www/lib/authors.json+++ b/apps/www/lib/authors.json@@ -314,5 +314,12 @@"position": "Engineering","author_url": "https://github.com/laktek","author_image_url": "https://github.com/laktek.png"+ },+ {+ "author_id": "saltcod",+ "author": "Terry Sutton",+ "position": "Engineering",+ "author_url": "https://github.com/saltcod",+ "author_image_url": "https://github.com/saltcod.png"}]diff --git a/apps/www/public/images/blog/lw7-studio/api-autodocs.png b/apps/www/public/images/blog/lw7-studio/api-autodocs.pngnew file mode 100644index 00000000000..a313b6e437fBinary files /dev/null and b/apps/www/public/images/blog/lw7-studio/api-autodocs.png differdiff --git a/apps/www/public/images/blog/lw7-studio/cascade-deletes.png b/apps/www/public/images/blog/lw7-studio/cascade-deletes.pngnew file mode 100644index 00000000000..ad34f7b7c57Binary files /dev/null and b/apps/www/public/images/blog/lw7-studio/cascade-deletes.png differdiff --git a/apps/www/public/images/blog/lw7-studio/cmdk-1.png b/apps/www/public/images/blog/lw7-studio/cmdk-1.pngnew file mode 100644index 00000000000..4dea0923de3Binary files /dev/null and b/apps/www/public/images/blog/lw7-studio/cmdk-1.png differdiff --git a/apps/www/public/images/blog/lw7-studio/cmdk-2.png b/apps/www/public/images/blog/lw7-studio/cmdk-2.pngnew file mode 100644index 00000000000..b691094e878Binary files /dev/null and b/apps/www/public/images/blog/lw7-studio/cmdk-2.png differdiff --git a/apps/www/public/images/blog/lw7-studio/cmdk-3.png b/apps/www/public/images/blog/lw7-studio/cmdk-3.pngnew file mode 100644index 00000000000..93ffbb7f923Binary files /dev/null and b/apps/www/public/images/blog/lw7-studio/cmdk-3.png differdiff --git a/apps/www/public/images/blog/lw7-studio/cmdk-4.png b/apps/www/public/images/blog/lw7-studio/cmdk-4.pngnew file mode 100644index 00000000000..76e25633397Binary files /dev/null and b/apps/www/public/images/blog/lw7-studio/cmdk-4.png differdiff --git a/apps/www/public/images/blog/lw7-studio/cmdk-5.png b/apps/www/public/images/blog/lw7-studio/cmdk-5.pngnew file mode 100644index 00000000000..8a299f41311Binary files /dev/null and b/apps/www/public/images/blog/lw7-studio/cmdk-5.png differdiff --git a/apps/www/public/images/blog/lw7-studio/definitions.png b/apps/www/public/images/blog/lw7-studio/definitions.pngnew file mode 100644index 00000000000..0efeb206da6Binary files /dev/null and b/apps/www/public/images/blog/lw7-studio/definitions.png differdiff --git a/apps/www/public/images/blog/lw7-studio/foreign-table-lookup-1.png b/apps/www/public/images/blog/lw7-studio/foreign-table-lookup-1.pngnew file mode 100644index 00000000000..8575ad980b6Binary files /dev/null and b/apps/www/public/images/blog/lw7-studio/foreign-table-lookup-1.png differdiff --git a/apps/www/public/images/blog/lw7-studio/foreign-table-lookup-2.png b/apps/www/public/images/blog/lw7-studio/foreign-table-lookup-2.pngnew file mode 100644index 00000000000..35ddb47dbc8Binary files /dev/null and b/apps/www/public/images/blog/lw7-studio/foreign-table-lookup-2.png differdiff --git a/apps/www/public/images/blog/lw7-studio/foreign-table-lookup-3.png b/apps/www/public/images/blog/lw7-studio/foreign-table-lookup-3.pngnew file mode 100644index 00000000000..624583356bdBinary files /dev/null and b/apps/www/public/images/blog/lw7-studio/foreign-table-lookup-3.png differdiff --git a/apps/www/public/images/blog/lw7-studio/foreign-table-lookup-4.png b/apps/www/public/images/blog/lw7-studio/foreign-table-lookup-4.pngnew file mode 100644index 00000000000..9d7d3a98bcbBinary files /dev/null and b/apps/www/public/images/blog/lw7-studio/foreign-table-lookup-4.png differdiff --git a/apps/www/public/images/blog/lw7-studio/foreign-table-lookup-5.png b/apps/www/public/images/blog/lw7-studio/foreign-table-lookup-5.pngnew file mode 100644index 00000000000..f3c86482b93Binary files /dev/null and b/apps/www/public/images/blog/lw7-studio/foreign-table-lookup-5.png differdiff --git a/apps/www/public/images/blog/lw7-studio/foreign-table-lookup-6.png b/apps/www/public/images/blog/lw7-studio/foreign-table-lookup-6.pngnew file mode 100644index 00000000000..e1ad302ac9dBinary files /dev/null and b/apps/www/public/images/blog/lw7-studio/foreign-table-lookup-6.png differdiff --git a/apps/www/public/images/blog/lw7-studio/foreign-table-lookup-7.png b/apps/www/public/images/blog/lw7-studio/foreign-table-lookup-7.pngnew file mode 100644index 00000000000..97b5f91250dBinary files /dev/null and b/apps/www/public/images/blog/lw7-studio/foreign-table-lookup-7.png differdiff --git a/apps/www/public/images/blog/lw7-studio/graphiql.png b/apps/www/public/images/blog/lw7-studio/graphiql.pngnew file mode 100644index 00000000000..3be28165ea6Binary files /dev/null and b/apps/www/public/images/blog/lw7-studio/graphiql.png differdiff --git a/apps/www/public/images/blog/lw7-studio/query-performance.png b/apps/www/public/images/blog/lw7-studio/query-performance.pngnew file mode 100644index 00000000000..499210a0a3fBinary files /dev/null and b/apps/www/public/images/blog/lw7-studio/query-performance.png differdiff --git a/apps/www/public/images/blog/lw7-studio/roles.png b/apps/www/public/images/blog/lw7-studio/roles.pngnew file mode 100644index 00000000000..d6718a6c05aBinary files /dev/null and b/apps/www/public/images/blog/lw7-studio/roles.png differdiff --git a/apps/www/public/images/blog/lw7-studio/webhooks.png b/apps/www/public/images/blog/lw7-studio/webhooks.pngnew file mode 100644index 00000000000..feee0616f4eBinary files /dev/null and b/apps/www/public/images/blog/lw7-studio/webhooks.png differ