Commit Graph
73 Commits
Author SHA1 Message Date
Ivan VasilovandCharis Lam 0cb08341f6 chore: Bump nextjs for the docs app (#35333)
* Bump all versions of postcss to 8.5.3.

* Run next/codemod on the docs app.

* Move two experimental flags into stable. Add next-mdx-remote as a transpiled package.

* Add extra folders to the clean command in docs.

* Fix type errors in docs test.

* Run prettier on the new files.

* remove turbopack, fix fetch revalidation, fix metadata awaits

Couple of minor fixes:
- Turbopack doesn't work in dev because of known MDX loader limitations
(cannot load functions in MDX plugin config)
- Fetches not cached by default anymore in Next 15 so need to manually
cache the ones we need
- Missing a few awaits for metadata generation with page params

* Bump the graphiql version because headlessui/react is not building with Next 15.

---------

Co-authored-by: Charis Lam <26616127+charislam@users.noreply.github.com>
2025-05-08 09:27:22 +00:00
Ivan Vasilov 94dd5648a3 chore: Revert the iframes options on docs. Set them on www. (#34445)
Revert the iframes on docs. Set them on www.
2025-03-26 21:14:09 +01:00
Ivan Vasilov 3c0cb1a4e7 chore: Fix iframes for Library (#34438)
* Fix the installation urls in production.

* Enable SAMEORIGIN for iframes on supabase.com.

* Remove extra config.
2025-03-26 17:04:07 +01:00
Charis 311232b3e1 feat(docs): ts hover annotations on code blocks (#34327) 2025-03-21 15:48:32 -04:00
Stephen Morgan 470db8a0f4 Added hsts preload directive to vercel config (#33980) 2025-03-05 08:56:59 +13:00
Stephen Morgan 71a108ef92 Second phase of HSTS header settings (#33857)
apply second phase of hsts header settings
2025-02-27 19:27:40 +13:00
Stephen MorganandAlaister Young c8824e445b Added hsts header via vercel.json (#33571)
* Added hsts header via vercel.json

* Migrate headers to next.config.js

* only apply hsts headers when running on vercel

* remove is platform check from docs

* Moved hsts header to root path

* Removed debugging header

* revert environment check on www header

---------

Co-authored-by: Alaister Young <a@alaisteryoung.com>
2025-02-21 07:31:57 +13:00
Alaister Young a6c8165abf chore(studio): cache favicon (#33372)
* chore(studio): cache favicon

* updates rules

* add to docs and www
2025-02-06 14:17:31 +08:00
Alaister Young f255627391 chore(docs): static assets cdn (#33347)
* chore(docs): static assets cdn

* r2 env vars

* embed asset url directly
2025-02-05 15:58:07 +00:00
Charis 699f708b0c fix: make examples available for isr (#32610)
The examples folder needs to be explicitly included in the Vercel Serverless bundle. Because it's at the root of the monorepo rather than being within the `app/docs` folder, we copy it over pre-build (and pre-dev).

Test the examples/prompts fix by re-enabling revalidations on graphql pages. Added a temp version of the fetch function so we can gradually reenable and monitor Vercel error rates over time.
2025-01-14 18:38:21 -05:00
Ivan Vasilov 06aa80e9f0 chore: Bump next to non-vulnerable version (#31277)
* Add next to pnpm catalog and use that next version from all apps and packages.

* Remove vite direct dependency.

* Set the @types/node to version 20.

* Stabilize supports-color by adding it in the main package.json. This will make it appear in all packages that have it as optional.

* Use built-in matchers for vitest in @testing-library/jest-dom.

* Add libpg-query as a dependency to docs.

* Remove nextjs-node-loader for the built-in external packages feature on nextjs.

* Clean up extra comment.
2025-01-03 13:25:00 +01:00
Julien Goux aa0fedfc39 chore: node v22 LTS compatibility for contributing (#30970)
* chore: node v22 LTS compatibility for contributing

* missing assertions

* apply prettier
2024-12-12 11:29:07 +01:00
Charis dcc3d4f267 fix(docs): integrations sidebar linking to missing partners (#29924)
Two related bugs:
- Not filtering partners on approved: true
- Not revalidating occasionally to pick up DB changes
2024-11-22 13:11:46 -05:00
Charis 93fb4b7692 fix(docs): force include reference mdx docs in vercel prod bundle (#30207) 2024-10-31 12:40:49 -04:00
Charis 41d924b074 feat: new docs ia (#29364)
New Docs IA, mainly splitting up the miscellaneous bucket that is Platform into multiple sections
2024-10-09 12:38:34 -04:00
Francesco Sansalvadore 7a7ce1c7a9 chore: remote patterns (#29263)
* chore: move domains to removePatterns in www

* chore: move domains to removePatterns in studio

* chore: move domains to removePatterns in docs

* fix
2024-09-17 20:33:13 +08:00
Chris GwilliamsandCharis Lam 1bdf45bf4f Set noindex for preview builds of docs site (#28761)
Co-authored-by: Charis Lam <26616127+charislam@users.noreply.github.com>
2024-09-04 11:40:25 -04:00
Charis fc164b5d07 Refactor/app router refs (#28095)
Migrates client SDK References to App Router. (Management and CLI API references aren't migrated yet, nor are self-hosting config references.)

Some notes:

Big changes to the way crawler pages are built and individual section URLs (e.g., javascript/select) are served. All of these used to be SSG-generated pages, but the number of heavy pages was just too much to handle -- slow as molasses and my laptop sounded like it was taking off, and CI sometimes refuses to build it all at all.

Tried various tricks with caching and pre-generating data but no dice.

So I changed to only building one copy of each SDK+version page, then serving the sub-URLs through a response rewrite. That's for the actual user-visible pages.

For the bot pages, each sub-URL needs to be its own page, but prebuilding it doesn't work, and rendering on demand from React components is too slow (looking for super-fast response here for SEO). Instead I changed to using an API route that serves very minimal, hand-crafted HTML. It looks ugly, but it's purely for the search bots.

You can test what bots see by running curl --user-agent "Mozilla/5.0 (iPhone; CPU iPhone OS 6_0 like Mac OS X) AppleWebKit/536.26 (KHTML, like Gecko) Version/6.0 Mobile/10A5376e Safari/8536.25 (compatible; Googlebot/2.1; +http://www.google.com/bot.html)" <URL_OF_PAGE>

Also added some smoke tests to run against prod for the crawler routes, since we don't keep an eye on those regularly, and Vercel config changes could surprise-break them. Tested the meta images on Open Graph and all seems to work fine.

With this approach, full production builds are really fast: ~5 minutes

Starts using the new type spec handling, which is better at finding params automatically, so I could remove some of the manually written ones from the spec files.
2024-08-13 16:12:59 -04:00
Jonathan Summers-MuirandFrancesco Sansalvadore 1f1f8a5fa4 Feat/whale init (#28243)
* duplicate page

* whale init

* table background

* prepare

* sync undocumented remote schema from master

* revert remote schema sync

* add lw12 tickets migration file

* ticket init

* set up lw12 ticket layout

* finish ticket layout and customization form

* lw12 ticket og

* ticket styling

* code highlight border

* launch week migrations

* local dev progress

* keep local gh config

* comment section

* comment section

* comment out username.tsx

* remove lw/ticekts temp

* update copy

* fix migration view

* redirect to try

* use misc

* lw12 og

* share

* share correct

* env var

* username page

* update example env

* push new db schema

* trigger deploy

* update ticket og

* ticket themes

* bypass browser

* change env var name

* fix

* fix

* process env

* create client server side

* lw announcements

* promoToast

* animated bg

* update ticket og bg

* minor details

* secret ticket

* social share text

* social share textgst

* flow text

* update og

* update og handler

* Update index.ts

* use functions.invoke and use generic supabase URL

* Update index.ts

* Update handler.tsx

* Update package-lock.json

* Update handler.tsx

* add next api route

* moved to vercel edge function

* set revalidate

* Update route.tsx

* Delete lw-ticket-og.tsx

* Update route.tsx

* Update [username].tsx

* Update [username].tsx

* add more fetches

* Update turbo.json

* ticket themes updated

* copy and layout updated

* Update index.tsx

* Update Ticket.tsx

* Update TicketingFlow.tsx

* update countdown

* updated bg

* small updates

* moat

* Update [username].tsx

* Update 20240723155310_add_lw12_ticketing_schema.sql

* optimistic ticket stuff og generation

* Update index.tsx

* updated layout

* update themes in og

* Update constants.ts

* attr renamed

* Update TicketingFlow.tsx

* Update TicketActions.tsx

* grammar

* moar updates

* Update TicketActions.tsx

* Update TicketActions2.tsx

* Update TicketActions.tsx

* Update Hero.tsx

* Update TicketingFlow.tsx

* remove console logs

---------

Co-authored-by: Francesco Sansalvadore <f.sansalvadore@gmail.com>
2024-08-01 01:59:01 +08:00
Kevin Grüneberg 4496c5a9ab chore: only lint in CI, not on Vercel (#28136) 2024-07-23 16:28:52 +08:00
Kevin Grüneberg b9c8b1c741 perf: skip docs typecheck during next build (#28089) 2024-07-19 12:56:27 -04:00
Kevin Grüneberg 14e29dc0a0 chore: remove mermaid, use static SVG (#28083) 2024-07-19 18:36:00 +08:00
Charis f4779d4844 refactor: migrate guides to app router (#23101)
Migrate guides to App Router.
2024-07-03 10:25:06 -04:00
github-actions[bot]andphamhieu a54aecd089 feat: update mgmt api docs (#27665)
Co-authored-by: phamhieu <689843+phamhieu@users.noreply.github.com>
2024-07-01 17:49:22 +00:00
Charis ac192a5024 refactor(docs): migrate home page to app router (#27221) 2024-06-24 18:47:53 -04:00
Jonathan Summers-MuirandIvan Vasilov c73af5ec8f move to shared types (#23210)
* move to shared types

* Rename the package to api-types.

* Fix a forgotten dependency.

* Add more forgotten deps.

---------

Co-authored-by: Ivan Vasilov <vasilov.ivan@gmail.com>
2024-04-24 11:03:17 +02:00
Jonathan Summers-MuirandIvan Vasilov d8ae6de7a8 feat: add new Icons package for custom made icons (#21477)
* feat: add new Icons package

* Create README.md

* add more icons

* add "Home" icon and "Postgres" icon

* reduce helpers

* remove old files

* make dev deps

* Delete package-lock.json

* Update README.md

* add to packages for other apps

* remove from db.design

* Update README.md

* Move the build-icons package in the packages folder.

---------

Co-authored-by: Ivan Vasilov <vasilov.ivan@gmail.com>
2024-02-26 09:40:56 +01:00
Ivan VasilovandTerry Sutton 5754c23abb feat: Move some components into ui-patterns (#20774)
* Change all imports in the ui package which import via the @ui shortcut.

* Add a new ui-patterns package. Add it to all apps.

* Migrate PrivacySettings from ui to ui-patterns.

* Migrate ConsentToast from ui to ui-patterns.

* Remove providers folder from ui package.

* Move GlassPanel.

* Migrate IconPanel.

* Migrate TweetCard.

* Migrate ThemeImage.

* Remove LWXCountdownBanner.

* Migrate CountdownWidget.

* Migrate SchemaTableNode.

* Migrate ExpandableVideo.

* Migrate ThemeToggle.

* Fix bunch of imports in the docs app.

* Revert some unnecessary changes.

* Expand the README.md.

* Fix the tailwind configs, they were using old folder structure.

* Fix leftover merge conflicts.

* Remove a deleted page in master.

---------

Co-authored-by: Terry Sutton <saltcod@gmail.com>
2024-02-12 12:44:00 +01:00
Ivan Vasilov 4dac01e378 chore: Migrate Clippy to Nextjs API docs (#20903)
* Add a new function to ai-commands package.

* Add a new API route to all three apps.

* Refactor the Command component to use the new URL.

* Resort the imports.
2024-02-12 10:10:52 +01:00
Jonathan Summers-MuirandCharis c222513546 [Docs] [Branching] Chore/branching docs (#18762)
* chore: initial branching docs added

* updated docs

* more changes

* Update tailwind.config.js

* Update branching.mdx

* Update tailwind.config.js

* more changes

* Update branching.mdx

* update images

* image refresh

* Delete example.jpg

* reword the top section

* Update branching.mdx

* image changeover

* Update next.config.mjs

* Apply suggestions from code review

Co-authored-by: Charis <26616127+charislam@users.noreply.github.com>

* Apply suggestions from code review

Co-authored-by: Charis <26616127+charislam@users.noreply.github.com>

* Apply suggestions from code review

* Apply suggestions from code review

---------

Co-authored-by: Charis <26616127+charislam@users.noreply.github.com>
2023-11-15 12:19:19 +00:00
Kevin Grüneberg 30958d87fb fix: build times storybook/swc (#18965) 2023-11-14 21:45:12 +01:00
8057309e51 chore: upgrade next 13 + react 18 (#17839)
* update deps + image codemod (studio)

* update next links (studio)

* update deps

* update links (ui)

* remove next-transpile-modules

* move next-themes dependency

* chore: update ConfirmDialog

* chore: remove old ConfirmModal js file. migrated to TS

* dependency wrangling

* remove empty page

* update next links (www)

* First run bump react-data-grid-v7 beta 4

* fix package-lock.json

* more deps wrangling

* update recharts

* update sentry options

* fix some broken things in www

* studio fixes

* fix graphiql

* fix studio build

* fix menu hydration

* small build error

* update turbo

* fix www typescript errors

* docs image codemod

* links codemod docs

* fix docs typescript errors

* move useConsent to ui to prevent circular deps

* Fix links

* Fix homepage

* Fix links

* move studio/ to apps/

* Revert "move studio/ to apps/"

This reverts commit 1b0a985fcb.

* disable outputFileTracingRoot

* remove outputFileTracingRoot

* fix homepage product cards

* fix PrivacySettings links

* Fix links

* Fix the build for www.

* Minor fixes for JWTGenerator.

* Fix the docs and ui tests.

* Revert codehike back to 0.8.3

* remove ConfirmAlert()

* reenable babel because mobx hates me

* fix blog image and comparison page avatar

* Fix svg errors

* update image synthax

* Fix code hike

* Move the button in a div so that it doesn't inherit its parent height and make the button look weird.

* When components are defined in a component, they get recreated on each render. This makes them unstable in certain cases and causes infinite rerenders.

* Replace the next/head usage with next/script.

* Chore/upgrade next 13 fix table editor (#18431)

* fix table editor styling and fix row deletion logic

* Fix deleting selected rows from header, and fix checkboxes not clearing up

* Fix deleting all rows when filter applied, and fix deleting all rows

* Fix grid size styling issue

* Fix TS error

* Hydration errors

* studio org pages fixes

* fix more studio links

* audit logs fixes

* dropdown icon styling fixes

* fix some images in www

* upgrade to next 14

* try new sentry wrapper for api

* see if this is even invoked

* Revert "see if this is even invoked"

This reverts commit 86c3973ffa.

* Revert "try new sentry wrapper for api"

This reverts commit f67623ebad.

* Revert "upgrade to next 14"

This reverts commit a24dd6131e.

* chore: allow node version 19/20

* Try to fix the LogTable so that it renders with the newer "react-data-grid" version.

* Fix type errors in the log renderer code.

* Fix the replication screen.

* Add the CSS for the GraphiQL.

* Fix SQL editor results rendering

* Lint

* Fix SQL editor results height issue

* Fix auth RLS not invalidating RQ when toggling RLS

* Fix database tables new/edit column regressed

* Fix migrations page empty state if migrations schema not yet created

* Fix API side panel docs temp remove postgrest text for column description PK and FK

* Fix + improve timeout handling in SQL editor

---------

Co-authored-by: Jonathan Summers-Muir <MildTomato@users.noreply.github.com>
Co-authored-by: Joshen Lim <joshenlimek@gmail.com>
Co-authored-by: Francesco Sansalvadore <f.sansalvadore@gmail.com>
Co-authored-by: Terry Sutton <saltcod@gmail.com>
Co-authored-by: Ivan Vasilov <vasilov.ivan@gmail.com>
Co-authored-by: Kevin Grüneberg <k.grueneberg1994@gmail.com>
2023-10-31 05:51:46 +00:00
Greg Richardson 2a3d243a34 Docs: Redirect relative dashboard/blog links in dev/preview envs (#18542)
* feat(docs): redirect relative dashboard links in dev/preview envs

* feat(docs): redirect blog posts in dev/preview envs
2023-10-30 09:18:51 -06:00
Greg Richardson e207378f2d Fix: search edge function URL (#18416)
fix: search edge function url
2023-10-24 10:51:14 -06:00
Oliver RiceandGreg Richardson 3fe7613b42 Expand Serverless APIs to REST + GraphQL (#17654)
* graphql section

* fix(federation): markdown image links

* feat(federation): support mkdocs admonition title

* feat(federation): remark pymdown tab support

* fix codehike path

* graphql icon renders

* replace serverless-apis with REST

* run prettier

* update serverless apis ref

* remove GraphQL and Realtime references from REST docs

* move realtime example to realtime overview section

* new section for apis

* prettier

* product label

* move realtime back to products

* feat: graphql nav menu + simplified path

* chore: remove console log

---------

Co-authored-by: Greg Richardson <greg.nmr@gmail.com>
2023-09-25 15:17:31 -06:00
Francesco Sansalvadore d0a2e18fe0 lw8: add LWAnnouncement to docs 2023-08-07 16:25:19 +02:00
Alaister Young 6cf66fbda4 Merge branch 'master' into chore/upgrade-to-node-18 2023-06-09 19:37:22 +10:00
Kevin Grüneberg 07ea342bf9 fix: docs build 2023-06-08 10:59:57 +02:00
Terry Sutton 40d3e0b346 Merge branch 'master' into chore/upgrade-to-node-18 2023-06-06 15:05:10 -02:30
Isaiah Hamilton eecce2eab7 move code hike to shared config 2023-06-05 23:40:16 -04:00
Greg Richardson b8df7d7c2b feat(docs): code hike 2023-06-04 15:15:58 -06:00
Greg Richardson 8d7f7a20ee fix: docs esm build errors 2023-05-30 12:22:23 -06:00
Andy Kenward 6031ffbe9b feat: allow image domain for keyri 2023-05-16 21:21:35 +00:00
Andy Kenward 659208ad1c fix: mdxRs unsupported with current setup 2023-05-16 13:23:30 +00:00
Terry Sutton f982243160 Merge pull request #14224 from supabase/fs/docs-polish
chore: docs polish
2023-05-10 15:16:45 -02:30
Francesco Sansalvadore e75fe11b91 feat: add featured video in docs table of content 2023-05-08 20:02:37 +02:00
Greg Richardson ed8798e60c chore(docs): lodash tree shaking 2023-05-04 17:54:45 -06:00
Greg Richardson de1634a4a9 chore(docs): bundle analyzer 2023-05-04 17:53:39 -06:00
Greg Richardson eb0a124ee1 chore(docs): adds redirect from root to /docs 2023-03-21 13:13:04 -06:00
Terry Sutton 083047df7c Add img provider 2023-02-10 15:57:25 -03:30