Is it just:class myWhatever { ... } exports.myWhatever = myWhatever; ?EDIT: Figured it out. The answer is yes. Make sure you use the module.class in the instantiation, e.g. :var wev = require('mywhatever'); var whatever = new wev.myWhatever();
Submitted October 30, 2018 at 06:09AM by poor-toy-soul-doll
No comments:
Post a Comment