docs: warn that re-seeding reverts admin-panel edits
This commit is contained in:
@@ -9,7 +9,7 @@ Public marketing site for Braids by Mira — landing page, product showcase, boo
|
|||||||
- `npm run build` — type-check and build for production
|
- `npm run build` — type-check and build for production
|
||||||
- `npm run lint` — run ESLint
|
- `npm run lint` — run ESLint
|
||||||
- `npm run test:functions` — run the Deno tests for the Edge Functions' shared email builders (requires [Deno](https://deno.com) installed)
|
- `npm run test:functions` — run the Deno tests for the Edge Functions' shared email builders (requires [Deno](https://deno.com) installed)
|
||||||
- `npm run seed` — seed products, services, and the default schedule into a Supabase project (see below)
|
- `npm run seed` — seed products, services, and the default schedule into a Supabase project (see below). Re-running it after admin-panel edits will revert those rows to the hardcoded seed defaults — use it for initial setup / disaster recovery, not routine use.
|
||||||
|
|
||||||
## Backend (Supabase)
|
## Backend (Supabase)
|
||||||
|
|
||||||
|
|||||||
@@ -5,6 +5,9 @@ import { createClient } from '@supabase/supabase-js'
|
|||||||
// `src/data/products.ts` and `src/data/services.ts` now fetch live rows from Supabase
|
// `src/data/products.ts` and `src/data/services.ts` now fetch live rows from Supabase
|
||||||
// (see Tasks 2-3 of this plan) instead of exporting static arrays, so this seed script
|
// (see Tasks 2-3 of this plan) instead of exporting static arrays, so this seed script
|
||||||
// owns its own copy of the seed data below rather than importing it from application code.
|
// owns its own copy of the seed data below rather than importing it from application code.
|
||||||
|
// WARNING: re-running this after admin-panel edits will revert those rows to these seed
|
||||||
|
// defaults (unconditional upsert keyed on id). Intended for initial setup / disaster
|
||||||
|
// recovery only, not routine use.
|
||||||
interface SeedProduct {
|
interface SeedProduct {
|
||||||
id: string
|
id: string
|
||||||
name: string
|
name: string
|
||||||
|
|||||||
Reference in New Issue
Block a user