<Image>
├── LICENSE
├── README.md
├── astro.config.mjs
├── package.json
├── public
│ ├── _headers
│ └── favicon.svg
├── src
│ ├── assets
│ │ └── astro.svg
│ ├── components
│ │ └── AstroLogo.astro
│ ├── content
│ │ ├── blog
│ │ │ ├── 2nd-post.md
│ │ │ └── first-post.md
│ │ └── images
│ │ ├── birch-trees.webp
│ │ └── sunset-cambridge.jpg
│ ├── content.config.ts
│ ├── layouts
│ │ └── Layout.astro
│ ├── pages
│ │ ├── 404.astro
│ │ ├── blog
│ │ │ └── [id].astro
│ │ └── index.astro
│ └── styles
│ └── global.css
├── tailwind.config.mjs
├── tsconfig.json
└── wrangler.toml
Command | Action |
---|---|
pnpm install |
Installs dependencies |
pnpm dev |
Starts local dev server at localhost:4321 |
pnpm build |
Build your production site to ./dist/ |
pnpm preview |
Preview your build locally, before deploying |
Cloudflare Pages will auto-build and republish on every commit if you link to your git repo.
Alternatively, you can push builds directly from your local machine using Wrangler.
wrangler.toml
to suit your projectpnpm wrangler login
- authenticates with Cloudflare (one time)pnpm ship
- runs astro build && wrangler pages deploy[!TIP] Set the site name in
astro.config
to generate canonical URLs.
Copyright (c) 2024-present, Jürgen Leschner (@jldec) MIT License