pierregoutheraud / atom-js-console

MIT License
10 stars 0 forks source link

Does not recognise console.log() #8

Closed whenmoon closed 4 years ago

whenmoon commented 5 years ago
screen shot 2019-02-01 at 17 57 22
TomWestrope commented 5 years ago

I am also getting this same issue

hvquy001 commented 5 years ago

Go to Packages / Atom Js Console -> View Code -> Open lib/Editor.js find sandbox variable and replace by that: const sandbox = { window, ...window, console: { log: function(str){ stdout.push(str); } } }

jrvieira commented 4 years ago

It's an environmental API, not part of JS itself. You can be working within an environment that doesn't implement it. Even if we assume the environment, its return value should be undefined.