Skip to content

Repository files navigation

Astro Tutorial Project

Tutorial Link

npm create astro@latest

🚀 Project Structure

Inside of this Astro project, you'll see the following folders and files:

/
├── public/
├── src/
| └── components/
| └── layouts/
│ └── pages/
| └── posts/
| └── tags/
│ └── index.astro
| └── scripts/
| └── styles/
| └── tags/
└── package.json

Astro looks for .astro or .md files in the src/pages/ directory. Each page is exposed as a route based on its file name.

There's nothing special about src/components/, but that's where we like to put any Astro/React/Vue/Svelte/Preact components.

Any static assets, like images, can be placed in the public/ directory.

🧞 Commands

All commands are run from the root of the project, from a terminal:

CommandAction
npm installInstalls dependencies
npm run devStarts local dev server at localhost:3000
npm run buildBuild your production site to ./dist/
npm run previewPreview your build locally, before deploying
npm run astro ...Run CLI commands like astro add, astro check
npm run astro -- --helpGet help using the Astro CLI

About

Astro blog website

Topics

Resources

Stars

1 star

Watchers

0 watching

Forks

Contributors

Languages