Building jot

Notes will be markdown, I'll probably use Marked (EDIT: I went with react-markdown)

Looking around for info on [[]], it looks like this is commonly referred to as "Wiki links" and there are some nice tools for using them in VSCode.

Don't know how long I'll be writing notes in VSCode though, so I'll sort of ignore for now. I just wanna see how easily I can parse them.

Some collected notes on progess:

Referenced in:
Genesis
This first note was created by making a new directory, notes, and placing a textfile titled 20201017094627 inside of it. I am typing in it now. Creating the filename was the hardest part, let's build a script to help. Jotting down a new note I am documenting some of the process in Building jot.
Jot
This is where I collect my thoughts. Inspired by Andy Matuschak and, in some ways, the Zettelkasten - I jot down my thoughts and make no attempt to index them. There is no list of recent posts. They are only discoverable when they are linked to and from. Here is what I'm currently working on / thinking about: A new BASIC programming language Incremental progress Building jot Authoring notes This collection contains {notes} notes linked together {links} times with {words} total words.

Node.js fs promises

Huh, neat. https://nodejs.org/dist/latest-v10.x/docs/api/fs.html##fs_fs_promises_api

44 minutes in

44 minutes in I'm now able to read in my posts and parse Backlinks. I had to learn negative lookbehinds to do this since I wanted to allow code samples such as [[foo]] untouched. Works similarly to lookahead which I'm familiar with.

I'd like to write this out to HTML somehow to prototype an interface, then I'll build forward links. Committing and taking a break for now.

Displaying the notes

Andy Matuschak's notes will serve as a pretty big inspiration for these. One key difference is brevity.

I'd like to display my notes in more of a "card" format than something that better serves long-form writing. I'm just not good at long-form writing.

I'll probably use Next.js because, as much as I'd like to build my own slim thing - Next is really, really good.

Hello, next!

Yeah Next.js served me well (thanks, team!). Make a pages/ directory, [id].js with getStaticPaths and getStaticProps and done.

I also swapped out the markdown. Marked is good but I wanted to leverage next/link and the following GitHub discussion (I didn't even know GitHub had discussions?) gave some working code with react-markdown: https://github.com/vercel/next.js/discussions/17088

Links out, links in

Linking out and in was trivial :) For now I'll display em after the post contents. When I get serious about Displaying the notes I'll figure out how to make cards pretty.

next/link is really easy to use. Just <Link href="...">...</Link> and you've got client-side routing for free. Continually impressed with Next.

I'd like to deploy to see if it's really that fast. Each time a post is rendered I might be regenerating the database (reading from the filesystem...). Anyway let's see how it holds up.