rsdiaz / astro-blog-template

A simple Astro.js starter blog template.

Home Page:https://astro-blog-template.pages.dev/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Welcome to Astromnl Blog Template

A simple blog built using Astro

screenshot

πŸš€ Project Structure

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

/
β”œβ”€β”€ public/
β”‚   β”œβ”€β”€ code.png
β”‚   └── robots.css
β”‚   └── global.css
β”‚   └── favicon.ico
β”œβ”€β”€ src/
β”‚   β”œβ”€β”€ posts/
β”‚   β”‚    └── *.md
β”‚   β”œβ”€β”€ components/
β”‚   β”‚   └── Footer.astro
β”‚   β”‚   └── Header.astro
β”‚   β”‚   └── MainHead.astro
β”‚   β”‚   └── PostCard.astro
β”‚   β”‚   └── PostList.astro
β”‚   β”‚   └── Pagination.astro
β”‚   β”œβ”€β”€ layouts/
β”‚   β”‚    └── BlogPost.astro
β”‚   β”‚    └── MainLayout.astro
β”‚   β”œβ”€β”€ pages/
β”‚       └── tags.astro
β”‚       └── index.astro
β”‚       └── index.astro
β”‚       └── contact.astro
β”‚       β”œβ”€β”€ tags/
|       |   └── [tag].astro
β”‚       β”œβ”€β”€ blog/
|           └── [slug]/
|           |   └── index.astro
|           └── [all]/
|               └── [...page].astro
└── 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:

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?

Feel free to check Astro documentation or jump into our Astro Discord server.

To-Do

  • Add tags
  • Fix index page
  • Fix post page
  • Add post title
  • Add code styling
  • Add contact page
  • Fix navigation links
  • Add pagination to tags
  • Change pagination styling

Credits

This template is inspired from works the following people :

About

A simple Astro.js starter blog template.

https://astro-blog-template.pages.dev/


Languages

Language:Astro 53.7%Language:CSS 40.7%Language:JavaScript 5.6%