Skip to content

πŸš€ A basic CMS site with a minimal theme requiring no coding knowledge. All pages and posts are created via the admin UI and written in markdown.

License

Notifications You must be signed in to change notification settings

christopher-aldred/astro-decap-cms-site

Β 
Β 

Repository files navigation

Astro & Decap CMS Site πŸš€

A basic CMS site with a minimal theme requiring no coding knowledge. All pages and posts are created via the admin UI and written in markdown.

screenshot

Features

  • πŸš€ Create posts & pages via Admin UI
  • πŸ—’οΈ Write content in markdown (also supports html)
  • πŸŒ“ Light & dark theme
  • πŸ’― Posts pagination
  • πŸ”– View posts by tag
  • πŸ”Ž Search posts (Coming soon)

Getting Started

1 - Deploy to netlify

Deploy to Netlify

2 - Set up Netlify Identity

  • Site configuration --> Identity --> Enable Identity --> Enable Git Gateway ( In Services Section of Identity )
  • You can allow Registration or Invite Only
  • For Invite Only: Integrations --> Identity --> Invite Users --> Send invite email

3 - Add an admin user

  • Site configuration --> Identity --> Users --> Invite user
  • You will need to verify email and set a password

4 - Navigate to your sites admin page

  • www.your-site.com/admin

5 - Login with the newly created admin account

Tech stack

How it works

  • Static site generation on Netlify

  • Decap CMS pushes changes to github which are redeployed in under a minute

  • Requires Netlify Identity (Can be manually replaced with other Oauth services)

    • Preview styles and templates won't be applied in dev server, but the cms will work
    • For actual use / local testing it's best to pnpm run build && pnpm run preview
    • If you are using windows you will need to edit the package.json's dev and preview commands to "dev": "start decap-server & start astro dev" and "preview: "start decap-server & start astro preview"
  • Netlify Identity widget must be on root page ( is in src/layouts/PageLayout.astro but only needs to be on root page ) and /admin

  • The decap admin board is preconfigured with preview styles built from the tailwind of our project and to only show the body in the preview ( personal preference of mine can be removed by removing the scripts in /pages/admin.astro)

  • Tailwind typography for styling the blogs

Decap with oAuth Routes in Astro

https://github.com/OliverSpeir/astro-decap-starter-ssr

About

πŸš€ A basic CMS site with a minimal theme requiring no coding knowledge. All pages and posts are created via the admin UI and written in markdown.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Astro 66.3%
  • CSS 14.4%
  • JavaScript 11.2%
  • TypeScript 8.1%