a simple, static, single page blog that features:
DEMO: https://qualityshepherd.github.io/splog/
- Markdown support for posts (with YAML metadata)
- simple
#hash
routing - index searching
- vanilla js!
- a post indexer:
src/lib/genr8.js
(ie. no DB) - load more-style pagination
- blog rss builder
- podcast rss builder
- blog posts with future dates are not displayed in lists (blog, search, tag, etc...) but ARE displayed by post. This allows drafts (set date to future) and/or setting posts to publish in the future. You'll still need to push a change for it to index (or cron the indexer?)
assumes Node and Git...
- clone:
git clone git@github.com:qualityshepherd/splog.git
cd splog
- install dependencies:
npm i
- add your markdown posts to
/posts
folder - edit the package.json
splog
section with your details npm start
to build index, rss and pack it- run web server (if needed):
npm run server
- http://lvh.me:4242/
when you add posts or make changes
- run
npm start
- you may need to clear your browser cache to see changes
- edit
package.json
splog
section to change:pathToIndex
- splog's flatfile dbpathToPostsFolder
- where you keep your .md postsmaxPosts
- the number of posts to display per "page"
- edit index.html (but leave
#main
) - add/edit views/pages in
src/views
to render html (injected into#main
) - adjust add news views to
src/router.js
- add posts written in Markdown (must have .md ext) to
/posts
- run
npm start
to publish new posts (creates new index and webpack in/dist
) and builds rss.xml
a script that builds an apple/spotify compatible rss xml file that you can submit to all the aggregators
- open
lib/podRss.js
and edit thepod
information to match your podcast npm run pod
ornpm start
to build the xml filepodRss.xml
- submit the link to the file (eg.
https://mydomain.com/podRss.xml
) to aggregatrors (eg. Spotify)