I am a complete Node.js newbie and struggling with the basics. Running this code on the server:
var http = require("http"),
sys = require("util"),
io = require("socket.io"),
GlobTrie = require("glob-trie.js");
Gives me an exception at the first require:
Uncaught ReferenceError: require is not defined
(anonymous function)
Any thoughts?
Best regards, Ben.
Node.js is run on the server side, not on the browser side.
Check out more about Node here: What is Node.js?
Case closed, I was including the wrong file on the client!
Sorry to waste people time, but thanks for the Node links.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With