A simple way to make a blog. Generate the posts as HTML files using whattever method you want. Then just add them to an edn file and the front-end code will make a nice index.
- Install dependencies on your workspace:
- babashka
- node
-
Try the development server:
npx shadow-cljs watch app
-
Compile your release build:
npx shadow-cljs release app
-
Copy these into your docroot:
- resources/public/cljs/{main.js,manifest.edn}
- add_post.clj
- resources/public/index.html
- resources/public/index.edn
-
Make sure your webserver serves .edn with the right mime-type
application/edn
-
Customize index.html with your branding
-
Empty the posts out of index.edn and use the add_post.clj script to add your new posts
If you want to do any real dev on it, it is a Shadow-cljs project. For how I put it together see here: https://readtheorg.xylon.me.uk/rr_clojurescript_with_shadow-cljs.html