Giter Site home page Giter Site logo

template's Introduction

zaduma

an Astro starter template for understated personal websites

Built with:

🏎️ Usage TLDR

  1. Click Use this template to create a new repo.
  2. Set VERCEL_TOKEN, VERCEL_PROJECT_ID, and VERCEL_ORG_ID secrets to deploy to Vercel from GHA (enables access to git history).
  3. Add OG_IMAGE_SECRET to secure your OG image endpoint.

See full usage instructions.

πŸ› Project Structure

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


β”œβ”€β”€ posts/
β”‚   └── rebuilding-a-blog.mdx β€” posts written in MDX
β”œβ”€β”€ public/ β€” static assets apart from images
β”œβ”€β”€ src/
β”‚   β”œβ”€β”€ build-time/* β€” remark plugins
β”‚   β”œβ”€β”€ global-styles/* β€” fonts, body and prose styles
β”‚   β”œβ”€β”€ layouts/
β”‚   β”‚   β”œβ”€β”€ BaseLayout.astro β€” UI shared between all pages
β”‚   β”‚   └── PostLayout.astro β€” layout for all posts
β”‚   β”œβ”€β”€ lib/* β€” reusable utils and UI components
β”‚   β”œβ”€β”€ images/* β€” pictures (need to be here to be optimized by Astro Image)
β”‚   β”œβ”€β”€ pages/
β”‚   β”‚   β”œβ”€β”€ [path].astro β€” Astro dynamic route for posts, supplies MDX components
β”‚   β”‚   └── index.astro β€” index page, lists all posts
β”‚   β”œβ”€β”€ env.d.ts
β”‚   └── types.ts
β”œβ”€β”€ astro.config.ts
β”œβ”€β”€ package.json
β”œβ”€β”€ postcss.config.cjs
β”œβ”€β”€ tailwind.config.cjs β€” Tailwind config, colors, fonts
└── tsconfig.json

🧞 Commands

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

Command Action
pnpm install Installs dependencies
pnpm run dev Starts local dev server at localhost:3000
pnpm run build Build your production site to ./dist/
pnpm run preview Preview your build locally, before deploying
pnpm run astro ... Run CLI commands like astro add, astro check
pnpm run astro --help Get help using the Astro CLI

πŸ‘Œ Usage

  1. Click Use this template to create a new repo.

  2. Clone the repository, install with pnpm install and run with pnpm dev.

  3. Style it and personalize however you like πŸ’…

  4. Set VERCEL_TOKEN, VERCEL_PROJECT_ID, and VERCEL_ORG_ID secrets to deploy to Vercel from GHA (what enables access to git history). (Settings→Secrets)

    • Alternatively β€” if all your blog posts have a date in frontmatter, you don't need to deploy through workflows/ci.yml. Feel free to remove the deploy steps from the YML file and connect Vercel/Netlify integration. Go to derivedTitleAndDatePlugin function and remove execSync("git log") from it. (TODO: Can we make it more convenient?)
  5. Generate a passphrase for OG_IMAGE_SECRET to secure your OG image endpoint, and add it to Actions Secrets.

template's People

Contributors

basuarunava avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    πŸ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. πŸ“ŠπŸ“ˆπŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❀️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.