Add .gitignore

My Mac puts .DS_Store files everywhere, I need to ignore them :)
Wrap JSON parsing in try/catch

On Chrome on my MacBook, it sometimes tries to parse JavaScript as
JSON, errors, and then doesn't display anything at all.

A try/catch deals with this (as well as improper JSON).