I am trying to play with node.js and send an xmlhttp request to the server from my server.js file using the node.js server object.
I defined the following at the beginning of my .js file:
var http = require('http');
var jsdom = require('jsdom');
var $ = require('jquery');
When I try to run a .js file using the nodejs console, I get the following error:
require (...). jsdom (...). createWindow is not a function
Is there something obvious that I'm missing?
I searched for the answers but no longer received.
source
share