javascript - TypeError: xxx is not a constructor -
var fishbowl = require('node-fishbowl'); var fb = new fishbowl.fishbowl({ host: 'x.x.x.x', iadescription: 'reporting dashboard', iaid: 2286, ianame: 'node-dashboard', password: 'x', port: '28192', username: 'x', bunyanlevel: 'debug' });
the above code returns "typeerror: fishbowl.fishbowl not constructor". i've tried can think of around have been unsuccessful.
running node.js v8.2.1
any appreciated.
that error in documentation, export fishbowl default
.
try this:
var fishbowl = require('node-fishbowl'); var fb = new fishbowl({ host: 'x.x.x.x', iadescription: 'reporting dashboard', iaid: 2286, ianame: 'node-dashboard', password: 'x', port: '28192', username: 'x', bunyanlevel: 'debug' });
Comments
Post a Comment