What is the node.js equivalent of window["myvar"] = value?
window["myvar"] = value
To set a global variable, use global instead of window.
global
window
global["myvar"] = value
2.1m questions
2.1m answers
60 comments
57.0k users