I am trying to create a NodeJS program that utilizes CasperJS within it. I have run into the error that the module 'casper' cannot be found. As a result, I have tried to npm install spooky --save as I have read around that it is a driver, but I am still getting the same error as I was getting before.
Also, before trying to install SpookyJS, I tried
var phantom = require('phantom');
phantom.casperPath = '/path/to/casperjs';
phantom.injectJs(phantom.casperPath + '/bin/bootstrap.js');
Which then gave me the error that injectJs is not a function. Any and all help appreciated.