One of the new features we'd like to have in DevEdition 40 is related to JSON rendering. Dev folks deal with JSON a lot these days and we want to make the work easier by rendering JSON as an expandable tree that allows easy inspection and filter/search.
One option to make this is implementing a stream convertor with contract-id: "@mozilla.org/streamconv;1?from=application/json&to=*/html" This means that any document with application/json (loaded into a tab) is auto converted into a little HTML app that allows easy inspection. See a screenshot here: http://snag.gy/rHivb.jpg This approach has one security implication, if the page uses "default-src 'none'" (or other security restrictions?) - injecting JS into it generates warnings: "Content Security Policy: The page's settings blocked the loading of a resource at self ("default-src 'none'")." Another option is introducing specific URL (like: chrome://browser/devtools/jsonviewer.xul) that implements the entire app and avoids JS injection in the existing content. But direct conversion of JSON documents is handy... and perhaps we have yet another option...? What do you think? What approach is the best here? (and without any security concerns) Honza _______________________________________________ dev-platform mailing list dev-platform@lists.mozilla.org https://lists.mozilla.org/listinfo/dev-platform