website

Jack Bendtsen's Personal Website

If you're reading this, you've arrived at the source code for the website itself! For more information, including why I developed this site the way I did, check out my blog!

Technical Features

  • Handwritten HTTP server loop, handwritten data structures
  • Thread per connection for sending and receiving, all processing done on main thread
  • Custom Markdown renderer
    • Doesn't follow the entire spec, but includes extra features not in the spec
  • Custom text/code editor widget, based on HTML canvas
    • Re-implements conventional editing features, eg.
      • Arrow movement (crtl+arrow for word movement, shift+arrow to select text)
      • Mouse input
      • Copy/cut/paste
    • DPI aware
    • Infinitely scrollable
      • Re-positions and redraws the canvas inside the outer div every 400px scrolled
  • Memory-only, read-only filesystem
    • All files are cached, the server has to be launched again after every change
  • Download project as an uncompressed ZIP
    • Compiles pointers to existing files in memory with ZIP header data into a list of buffers, which are written in one go with sendmsg()