ws / cards

Turn your Notion database into a deck of cards

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

This is my fork of cards. Jordan's is better. Go buy some jordancoin.

Some notable changes:

  • config.json file
  • use nunjucks for HTML templating
  • use the git-rev-sync dependency instead of calling childprocess
  • creates a pages.json file in the build directory with source content artifacts (just in case Notion disappears)
  • emoji alt text
  • rough callout support
  • link_to_page support
  • tweet embeds (with or without twitter styling/tracking) (caches to build/tweets.json)
  • footer backlink de-duplication (in case you link to the same page twice)
  • creates logical redirects (eg canonical_id_with_dashes.html always, short_id.html when a different pagename is used, etc.)

cards

Turn a Notion database into a deck of cards. I use this to power cards.jordanscales.com.

a desktop with notion open on the left and a rendered notion page using this library on the right

usage

As a heads up, this barely works at all. It works even less with Will's changes.

git clone https://github.com/jdan/cards.git
npm i
mv config.example.json config.json
# edit config.json with your notion secret + DB id
npx serve build   # build/ contains everything you need
# localhost:5000 now shows your cards

random notes

how to make a homepage

  1. create a Notion property called "Filename"
  2. set that property to index.html

About

Turn your Notion database into a deck of cards


Languages

Language:JavaScript 71.4%Language:CSS 19.6%Language:HTML 9.0%