$ keith tab to autocomplete
--home main --about who is this guy? --videos watch stuff --projects things I built --posts read things --concepts deep dives --contact get in touch --youtube subscribe
← cd ../posts
January 18, 2011 | 1 min read | 39 words

Sinatra rendering JSON with Datamapper

Sinatra rendering JSON with Datamapper

While this link is a good overview of rendering json, remember this if you’re using datamapper:

  1. Make sure you require dm-serializer
  2. Make sure you run @object.to_json to get clean output
  3. Profit!
Back to all posts

// EOF — Thanks for scrolling this far. You're curious too, aren't you?

// console.log("If you're reading this, we should talk.")

© 2026 Keith Posehn

> esc to close
↑↓ navigate ↵ select esc close
keith@local: ~
┬┌─┌─┐┬┌┬┐┬ ┬┌─┐┌─┐┌─┐┌─┐┬ ┬┌┐┌ ┌┐┌┌─┐┌┬┐
├┴┐├┤ │ │ ├─┤├─┘│ │└─┐├┤ ├─┤│││ │││├┤  │
┴ ┴└─┘┴ ┴ ┴ ┴┴  └─┘└─┘└─┘┴ ┴┘└┘o┘└┘└─┘ ┴
        

Welcome to the secret terminal. Type help to get started.

// Pro tip: This is an easter egg. You found it!

$