Better HN
top
new
best
ask
show
jobs
Log in
Sign up
Better HN
Comment
by
hmottestad
· 13y ago · 0 comments
I can recommend formatting the JSON. Like this:
demoElement.innerHTML = JSON.stringify(data, null, 4);
And then use "<pre>" tag in the demoElement.
Comments
[–]
premasagar
13y ago
A good idea. I've just added that to the docs site.
[–]
egeozcan
13y ago
That is the first thing I did using the web inspector. One could also use a js-beautifier I guess.