mirror of
https://github.com/waynesutton/markdown-site.git
synced 2026-01-12 04:09:14 +00:00
docs: add npm run sync:prod notes for production
Clarify when to use development vs production sync commands in setup-guide, about-this-blog, and markdown-with-code-examples
This commit is contained in:
@@ -72,9 +72,11 @@ The setup takes about 10 minutes:
|
||||
|
||||
1. Fork the repo
|
||||
2. Run `npx convex dev` to set up your backend
|
||||
3. Run `npm run sync` to upload posts
|
||||
3. Run `npm run sync` to upload posts (development) or `npm run sync:prod` (production)
|
||||
4. Deploy to Netlify
|
||||
|
||||
**Development vs Production:** Use `npm run sync` when testing locally against your dev Convex deployment. Use `npm run sync:prod` when deploying content to your live production site.
|
||||
|
||||
Read the [setup guide](/setup-guide) for detailed steps.
|
||||
|
||||
## Customization
|
||||
|
||||
@@ -85,9 +85,12 @@ npm install
|
||||
# Start development server
|
||||
npm run dev
|
||||
|
||||
# Sync posts to Convex
|
||||
# Sync posts to Convex (development)
|
||||
npm run sync
|
||||
|
||||
# Sync posts to Convex (production)
|
||||
npm run sync:prod
|
||||
|
||||
# Deploy to production
|
||||
npm run deploy
|
||||
```
|
||||
@@ -114,12 +117,13 @@ Reference files with inline code: `convex/schema.ts`, `src/pages/Home.tsx`.
|
||||
|
||||
## Tables
|
||||
|
||||
| Command | Description |
|
||||
| ---------------- | ------------------------ |
|
||||
| `npm run dev` | Start development server |
|
||||
| `npm run build` | Build for production |
|
||||
| `npm run sync` | Sync markdown to Convex |
|
||||
| `npx convex dev` | Start Convex dev server |
|
||||
| Command | Description |
|
||||
| -------------------- | ------------------------------ |
|
||||
| `npm run dev` | Start development server |
|
||||
| `npm run build` | Build for production |
|
||||
| `npm run sync` | Sync markdown to Convex (dev) |
|
||||
| `npm run sync:prod` | Sync markdown to Convex (prod) |
|
||||
| `npx convex dev` | Start Convex dev server |
|
||||
|
||||
## Lists
|
||||
|
||||
@@ -177,5 +181,5 @@ content/blog/
|
||||
|
||||
1. Keep slugs URL-friendly (lowercase, hyphens)
|
||||
2. Set `published: false` for drafts
|
||||
3. Run `npm run sync` after adding posts
|
||||
3. Run `npm run sync` after adding posts (or `npm run sync:prod` for production)
|
||||
4. Use descriptive titles for SEO
|
||||
|
||||
@@ -12,7 +12,7 @@ readTime: "8 min read"
|
||||
|
||||
This guide walks you through forking [this markdown site](https://github.com/waynesutton/markdown-site), setting up your Convex backend, and deploying to Netlify. The entire process takes about 10 minutes.
|
||||
|
||||
**How publishing works:** Once deployed, you write posts in markdown, run `npm run sync`, and they appear on your live site immediately. No rebuild or redeploy needed. Convex handles real-time data sync, so all connected browsers update automatically.
|
||||
**How publishing works:** Once deployed, you write posts in markdown, run `npm run sync` for development or `npm run sync:prod` for production, and they appear on your live site immediately. No rebuild or redeploy needed. Convex handles real-time data sync, so all connected browsers update automatically.
|
||||
|
||||
## Table of Contents
|
||||
|
||||
@@ -47,6 +47,7 @@ This guide walks you through forking [this markdown site](https://github.com/way
|
||||
- [Add Static Pages (Optional)](#add-static-pages-optional)
|
||||
- [Update SEO Meta Tags](#update-seo-meta-tags)
|
||||
- [Update llms.txt and robots.txt](#update-llmstxt-and-robotstxt)
|
||||
- [Real-time Stats](#real-time-stats)
|
||||
- [API Endpoints](#api-endpoints)
|
||||
- [Troubleshooting](#troubleshooting)
|
||||
- [Posts not appearing](#posts-not-appearing)
|
||||
|
||||
Reference in New Issue
Block a user