Skip to content

Commit

Permalink
Add package.json instructions to blog documentation (shuding#2919)
Browse files Browse the repository at this point in the history
Co-authored-by: Dimitri POSTOLOV <[email protected]>
  • Loading branch information
sidpremkumar and dimaMachina authored Sep 12, 2024
1 parent 7919d41 commit e203353
Showing 1 changed file with 19 additions and 0 deletions.
19 changes: 19 additions & 0 deletions docs/pages/docs/blog-theme/start.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,25 @@ npm i next react react-dom nextra nextra-theme-blog
install `nextra` and `nextra-theme-blog` as the add-ons.
</Callout>

Add the following scripts in `package.json`:

```json filename="package.json"
"scripts": {
"dev": "next",
"build": "next build",
"start": "next start"
},
```

You can either start the server with, for example if you use npm, `npm run dev`,
which will run in development mode or `npm run build && npm run start` for
production mode.

<Callout>
If you're not familiar with Next.js, note that development mode is
significantly slower since Next.js compiles every page you navigate to.
</Callout>

### Add Next.js Config

Create the following `next.config.js` file in your project’s root directory:
Expand Down

0 comments on commit e203353

Please sign in to comment.