Skip to content

The Postgres development platform. Supabase gives you a dedicated Postgres database to build your web, mobile, and AI applications.

feat(design-system): add contentlayer watch task to package.json (#38459)

kemal.earth168120889633
diff --git a/apps/design-system/README.md b/apps/design-system/README.md
index c4033664f80..47f009cebea 100644
--- a/apps/design-system/README.md
+++ b/apps/design-system/README.md
@@ -20,6 +20,16 @@ You can start editing the page by modifying `app/page.tsx`. The page auto-update
This project uses [`next/font`](https://nextjs.org/docs/basic-features/font-optimization) to automatically optimize and load Inter, a custom Google Font.
+### Watching for MDX changes
+
+If you would like to watch for changes to MDX files with hot reload, you can run the following command in a separate Terminal shell:
+
+```
+pnpm content:dev
+```
+
+This runs Contentlayer concurrently and watches for any changes.
+
## Learn More
To learn more about Next.js, take a look at the following resources:
diff --git a/apps/design-system/package.json b/apps/design-system/package.json
index 7a262a1a1a0..e6acd2763ef 100644
--- a/apps/design-system/package.json
+++ b/apps/design-system/package.json
@@ -10,6 +10,7 @@
"build:registry": "tsx --tsconfig ./tsconfig.scripts.json ./scripts/build-registry.mts && prettier --log-level silent --write \"registry/**/*.{ts,tsx,mdx}\" --cache",
"start": "next start",
"lint": "next lint",
+ "content:dev": "contentlayer2 dev",
"content:build": "contentlayer2 build",
"clean": "rimraf node_modules .next .turbo",
"typecheck": "contentlayer2 build && tsc --noEmit -p tsconfig.json"