diff options
author | 2021-07-15 14:13:35 -0400 | |
---|---|---|
committer | 2021-07-15 14:13:35 -0400 | |
commit | 166e22bdf35b9751dc42f5cc6cb27a99b077df93 (patch) | |
tree | e8643360c2250dda82ebf95b62281978547d5188 /docs/src/pages/quick-start.md | |
parent | fb8bf7ec43f7b09348c12d5ff9f81131c70ef5e9 (diff) | |
download | astro-166e22bdf35b9751dc42f5cc6cb27a99b077df93.tar.gz astro-166e22bdf35b9751dc42f5cc6cb27a99b077df93.tar.zst astro-166e22bdf35b9751dc42f5cc6cb27a99b077df93.zip |
merge in docs site (#705)
Diffstat (limited to 'docs/src/pages/quick-start.md')
-rw-r--r-- | docs/src/pages/quick-start.md | 50 |
1 files changed, 50 insertions, 0 deletions
diff --git a/docs/src/pages/quick-start.md b/docs/src/pages/quick-start.md new file mode 100644 index 000000000..9ebf92baf --- /dev/null +++ b/docs/src/pages/quick-start.md @@ -0,0 +1,50 @@ +--- +layout: ~/layouts/Main.astro +title: Quick Start +--- + +```shell +# prerequisite: check that Node.js is 12.20.0+, 14.13.1+, or 16+ +node --version + +# create a new project directory, and `cd` into it +mkdir mkdirtest && cd "$_" + +# prepare for liftoff... +npm init astro + +# install dependencies +npm install + +# start developing! +npm run start + +# when you're ready: build your static site to `dist/` +npm run build +``` + +To deploy your Astro site to production, upload the contents of the `/dist` folder (generated by running `npm run build`) to your favorite hosting provider. + +[Read more about deploying Astro in the Deploy guide.](/guides/deploy) + +## Start your project + +Go back to your command-line terminal, and run the following command in your project directory: + +```bash +npm start +``` + +Your application is now running on [http://localhost:3000](http://localhost:3000). Open this URL in your browser and you should see the text "Hello, World" that we copied in the previous step. + +Astro will listen for file changes in your `src/` directory, so you do not need to restart the application as you make changes during development. + +## Build your project + +Go back to your command-line terminal, and run the following command in your project directory: + +```bash +npm run build +``` + +This will build your site and write it to disk in the `dist/` directory. Astro sites are static, so they can be deployed to your favorite host (Vercel, Netlify, an S3 bucket, etc.). |