I am trying to open a debug window within Javascript. Javascript will pass the debug window a JSON string which JSONView (a Chrome extension) should display in a nicely form
It is not possible.
You'd be better off doing:
console.log(JSON.parse($(".trend_chart").attr("data-trendChart")));