docs: seperate npm run build
and npm run dev
to avoid confusion (#1798)
To avoid confusion I seperated the `npm run build` and the `npm run dev` commands, beginners might get confused by each command being listed in the same list, thinking they need to run `npm run build` before Astro works properly. Add `npm run preview` commands to all examples where they are missing
This commit is contained in:
parent
529486bfb0
commit
eb4effb6b7
17 changed files with 65 additions and 36 deletions
|
@ -19,7 +19,10 @@ npm install
|
|||
|
||||
# Fange an zu entwickeln!
|
||||
npm run dev
|
||||
```
|
||||
|
||||
Für Produktionsstandorte,
|
||||
```shell
|
||||
# Wenn du bereit bist: Exportiere deine Seite nach `dist/`
|
||||
npm run build
|
||||
```
|
||||
|
|
|
@ -19,7 +19,10 @@ npm install
|
|||
|
||||
# comienza con el desarrollo
|
||||
npm run dev
|
||||
```
|
||||
|
||||
Para los sitios de producción,
|
||||
```shell
|
||||
# cuando estés listo: crea tu sitio estático en la carpeta `dist/`
|
||||
npm run build
|
||||
```
|
||||
|
|
|
@ -19,7 +19,9 @@ npm install
|
|||
|
||||
# aloita kehittäminen!
|
||||
npm run dev
|
||||
```
|
||||
|
||||
```shell
|
||||
# kun olet valmis: luo oma staattinen sivustosi hakemistoon `dist/`
|
||||
npm run build
|
||||
```
|
||||
|
|
|
@ -19,7 +19,9 @@ npm install
|
|||
|
||||
# Commencez à coder !
|
||||
npm run dev
|
||||
```
|
||||
|
||||
```shell
|
||||
# Quand votre site est fin prêt, compilez-en une version statique dans le dossier `dist/`
|
||||
npm run build
|
||||
```
|
||||
|
|
|
@ -19,7 +19,9 @@ npm install
|
|||
|
||||
# 開発を始めよう
|
||||
npm run dev
|
||||
```
|
||||
|
||||
```shell
|
||||
# 準備ができたら、`dist/`に静的サイトを構築します。
|
||||
npm run build
|
||||
```
|
||||
|
|
|
@ -19,7 +19,9 @@ npm install
|
|||
|
||||
# start de ontwikkeling!
|
||||
npm run dev
|
||||
```
|
||||
|
||||
```shell
|
||||
# zodra je klaar bent, bouw dan je website met het volgende commanda
|
||||
npm run build
|
||||
```
|
||||
|
|
|
@ -19,7 +19,10 @@ npm install
|
|||
|
||||
# start developing!
|
||||
npm run dev
|
||||
```
|
||||
|
||||
For production sites,
|
||||
```shell
|
||||
# when you're ready: build your static site to `dist/`
|
||||
npm run build
|
||||
```
|
||||
|
|
|
@ -18,7 +18,9 @@ npm install
|
|||
|
||||
# начинаем разработку!
|
||||
npm run dev
|
||||
```
|
||||
|
||||
```shell
|
||||
# когда все готово: запустите сборку вашего статического сайта в директорию `dist/`
|
||||
npm run build
|
||||
```
|
||||
|
|
|
@ -19,7 +19,9 @@ npm install
|
|||
|
||||
# 启动项目
|
||||
npm run dev
|
||||
```
|
||||
|
||||
```shell
|
||||
# 将项目打包到 dist 文件夹下
|
||||
npm run build
|
||||
```
|
||||
|
|
|
@ -19,7 +19,9 @@ npm install
|
|||
|
||||
# 開始開發!
|
||||
npm run dev
|
||||
```
|
||||
|
||||
```shell
|
||||
# 做好之後:把靜態網站 build 進 `dist/`
|
||||
npm run build
|
||||
```
|
||||
|
|
|
@ -43,10 +43,11 @@ Any static assets, like images, can be placed in the `public/` directory.
|
|||
All commands are run from the root of the project, from a terminal:
|
||||
|
||||
| Command | Action |
|
||||
|:----------------|:--------------------------------------------|
|
||||
|:---------------- |:-------------------------------------------- |
|
||||
| `npm install` | Installs dependencies |
|
||||
| `npm run dev` | Starts local dev server at `localhost:3000` |
|
||||
| `npm run build` | Build your production site to `./dist/` |
|
||||
| `npm run preview` | Preview your build locally, before deploying |
|
||||
|
||||
## 👀 Want to learn more?
|
||||
|
||||
|
|
|
@ -43,10 +43,11 @@ Any static assets, like images, can be placed in the `public/` directory.
|
|||
All commands are run from the root of the project, from a terminal:
|
||||
|
||||
| Command | Action |
|
||||
|:----------------|:--------------------------------------------|
|
||||
|:---------------- |:-------------------------------------------- |
|
||||
| `npm install` | Installs dependencies |
|
||||
| `npm run dev` | Starts local dev server at `localhost:3000` |
|
||||
| `npm run build` | Build your production site to `./dist/` |
|
||||
| `npm run preview` | Preview your build locally, before deploying |
|
||||
|
||||
## 👀 Want to learn more?
|
||||
|
||||
|
|
|
@ -22,11 +22,11 @@ npm init astro -- --template docs
|
|||
All commands are run from the root of the project, from a terminal:
|
||||
|
||||
| Command | Action |
|
||||
|:-----------------|:---------------------------------------------|
|
||||
|:---------------- |:-------------------------------------------- |
|
||||
| `npm install` | Installs dependencies |
|
||||
| `npm run dev` | Starts local dev server at `localhost:3000` |
|
||||
| `npm run build` | Build your production site to `./dist/` |
|
||||
| `npm run preview`| Preview your build locally, before deploying |
|
||||
| `npm run preview` | Preview your build locally, before deploying |
|
||||
|
||||
To deploy your site to production, check out our [Deploy an Astro Website](https://docs.astro.build/guides/deploy) guide.
|
||||
|
||||
|
|
|
@ -32,10 +32,11 @@ Any static assets, like images, can be placed in the `public/` directory.
|
|||
All commands are run from the root of the project, from a terminal:
|
||||
|
||||
| Command | Action |
|
||||
|:----------------|:--------------------------------------------|
|
||||
|:---------------- |:-------------------------------------------- |
|
||||
| `npm install` | Installs dependencies |
|
||||
| `npm run dev` | Starts local dev server at `localhost:3000` |
|
||||
| `npm run build` | Build your production site to `./dist/` |
|
||||
| `npm run preview` | Preview your build locally, before deploying |
|
||||
|
||||
## 👀 Want to learn more?
|
||||
|
||||
|
|
|
@ -13,10 +13,11 @@ npm init astro -- --template portfolio
|
|||
All commands are run from the root of the project, from a terminal:
|
||||
|
||||
| Command | Action |
|
||||
|:----------------|:--------------------------------------------|
|
||||
|:---------------- |:-------------------------------------------- |
|
||||
| `npm install` | Installs dependencies |
|
||||
| `npm run dev` | Starts local dev server at `localhost:3000` |
|
||||
| `npm run build` | Build your production site to `./dist/` |
|
||||
| `npm run preview` | Preview your build locally, before deploying |
|
||||
|
||||
## 👀 Want to learn more?
|
||||
|
||||
|
|
|
@ -13,10 +13,11 @@ npm init astro -- --template portfolio
|
|||
All commands are run from the root of the project, from a terminal:
|
||||
|
||||
| Command | Action |
|
||||
|:----------------|:--------------------------------------------|
|
||||
|:---------------- |:-------------------------------------------- |
|
||||
| `npm install` | Installs dependencies |
|
||||
| `npm run dev` | Starts local dev server at `localhost:3000` |
|
||||
| `npm run build` | Build your production site to `./dist/` |
|
||||
| `npm run preview` | Preview your build locally, before deploying |
|
||||
|
||||
## 👀 Want to learn more?
|
||||
|
||||
|
|
|
@ -32,10 +32,11 @@ Any static assets, like images, can be placed in the `public/` directory.
|
|||
All commands are run from the root of the project, from a terminal:
|
||||
|
||||
| Command | Action |
|
||||
|:----------------|:--------------------------------------------|
|
||||
|:---------------- |:-------------------------------------------- |
|
||||
| `npm install` | Installs dependencies |
|
||||
| `npm run dev` | Starts local dev server at `localhost:3000` |
|
||||
| `npm run build` | Build your production site to `./dist/` |
|
||||
| `npm run preview` | Preview your build locally, before deploying |
|
||||
|
||||
## 👀 Want to learn more?
|
||||
|
||||
|
|
Loading…
Reference in a new issue