You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
i'm using the following code snippet with node v5.11.0, electron v1.4.13 and electron-microscope v2.0.0
I hope i'm not using it wrong. I'd be happy for a hint why the output$ stream is not logging anything.
varelectron=require('electron')varcreateMicroscope=require('electron-microscope')electron.app.on('ready',function(){createMicroscope(function(err,scope){if(err)throwerrvarurl='http://google.de'varcode='(function () { return document.title || "m3h" })()'varmicroscope=scope.window.webContentsfunctioncb(result){console.log(result)}scope.loadURL(url,function(){microscope.executeJavaScript(code,false,cb)varCODE=`function (send, done) { // put your custom code here // call 'send(data)' to write data to the stream // call 'done()' to end the stream // calling send is optional, but you must eventually call done to end the stream send(document.title) send('asdf') done() }`varoutput$=scope.run(CODE)// @TODO: `output$` emits no data :/output$.on('data',function(data){console.log('data: ',arguments)})output$.on('error',function(err){console.error(err)})})})})
The text was updated successfully, but these errors were encountered:
i'm using the following code snippet with
node v5.11.0
,electron v1.4.13
andelectron-microscope v2.0.0
I hope i'm not using it wrong. I'd be happy for a hint why the
output$
stream is not logging anything.The text was updated successfully, but these errors were encountered: