How to display JSON.parse reviver?

edited January 2017 in General


Am teaching myself and can receive data in the console with the following script. I am want to publish the JSON data to an HTML document.

code is:

var ws = new WebSocket('wss://');
ws.onopen = function(evt) {
        "ticks_history": "frxGBPUSD","end": "latest","count": 86400,"style":"candles","granularity": 3600

ws.onmessage = function(msg) {
   var data = JSON.parse(; console.log('ticks_history update: %o', data)

JSON.parse() requires a reviver for this Can someone point me in the right direction please?

Many thanks...

Best Answer


Sign In or Register to comment.