Skip to content

require(Socket.io).listen() is not a function #3

@Gowtham171996

Description

@Gowtham171996

var io = require('socket.io').listen(httpd);
^

TypeError: require(...).listen is not a function
at Object.exports.init (/home/gowtham/Desktop/localtests/node/near-realtime-node/dispatcher.js:8:32)
at Object. (/home/gowtham/Desktop/localtests/node/near-realtime-node/main.js:34:12)
at Module._compile (internal/modules/cjs/loader.js:778:30)
at Object.Module._extensions..js (internal/modules/cjs/loader.js:789:10)
at Module.load (internal/modules/cjs/loader.js:653:32)
at tryModuleLoad (internal/modules/cjs/loader.js:593:12)
at Function.Module._load (internal/modules/cjs/loader.js:585:3)
at Function.Module.runMain (internal/modules/cjs/loader.js:831:12)
at startup (internal/bootstrap/node.js:283:19)
at bootstrapNodeJSCore (internal/bootstrap/node.js:623:3)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions