Closed evanblack closed 9 years ago
Sorry - it's because I switched to an offline version of jQuery, but it's not resolving the directory - I've switched it back whilst I work out why it messed up. Just do an npm update
Hmmm. Still getting the same error...
Can you share what url you're testing - so I can try to replicate the problem?
Just doing: inliner http://remysharp.com
Here's my npm ls installed output:
npm info it worked if it ends with ok
npm info using npm@0.3.18
npm info using node@v0.5.0-pre
htmlparser@1.7.3 active installed Forgiving HTML/XML/RSS Parser in JS for both Node and Browsers
inliner@0.0.5 installed Utility to inline images, CSS and JavaScript for a web page - useful for mobile sites
inliner@0.0.6 installed Utility to inline images, CSS and JavaScript for a web page - useful for mobile sites
inliner@0.0.7 installed Utility to inline images, CSS and JavaScript for a web page - useful for mobile sites
inliner@0.0.8 active installed Utility to inline images, CSS and JavaScript for a web page - useful for mobil
jquery@1.5.1 active installed jQuery: The Write Less, Do More, JavaScript Library util dom jquery
jsdom@0.1.20 active installed CommonJS implementation of the DOM intended to be platform independent and as
jsdom@0.2.0 installed A javascript implementation of the W3C DOM dom w3c javascript
mime@1.2.2 active installed A comprehensive library for mime-type mapping util mime
mjsunit.runner@0.1.3 active installed Command line mjsunit runner which provides an easy way to hook into mjsunit an
npm@0.3.18 active installed A package manager for node package manager modules install package.json
request@1.9.5 active http installed simple util utility Simplified HTTP request client.
uglify-js@1.0.1 installed
uglify-js@1.0.2 active installed
Also noticed the jsdom wasn't using the latest so updated that, but with no luck...
Same for me. I've installed via both npm
and this repository.
$ → inliner --verbose http://remysharp.com
get http://remysharp.com
TypeError: Cannot call method 'runInContext' of undefined
at Object.javascript (/usr/local/lib/node_modules/inliner/node_modules/jsdom/lib/jsdom/level2/languages/javascript.js:17:14)
at Object._eval (/usr/local/lib/node_modules/inliner/node_modules/jsdom/lib/jsdom/level2/html.js:1195:46)
at /usr/local/lib/node_modules/inliner/node_modules/jsdom/lib/jsdom/level2/html.js:43:20
at Object.check (/usr/local/lib/node_modules/inliner/node_modules/jsdom/lib/jsdom/level2/html.js:235:11)
at /usr/local/lib/node_modules/inliner/node_modules/jsdom/lib/jsdom/level2/html.js:251:12
at IncomingMessage.<anonymous> (/usr/local/lib/node_modules/inliner/node_modules/jsdom/lib/jsdom/level2/html.js:85:11)
at IncomingMessage.emit (events.js:81:20)
at HTTPParser.onMessageComplete (http.js:133:23)
at Client.onData [as ondata] (http.js:1513:27)
at Client._onReadable (net_legacy.js:683:27)
at IOWatcher.onReadable [as callback] (net_legacy.js:177:10)
TypeError: Object #<Object> has no method '$'
at /usr/local/lib/node_modules/inliner/inliner.js:77:16
at /usr/local/lib/node_modules/inliner/node_modules/jsdom/lib/jsdom.js:207:13
at /usr/local/lib/node_modules/inliner/node_modules/jsdom/lib/jsdom.js:212:11
at Object.<anonymous> (/usr/local/lib/node_modules/inliner/node_modules/jsdom/lib/jsdom/level2/events.js:274:17)
at Object.dispatchEvent (/usr/local/lib/node_modules/inliner/node_modules/jsdom/lib/jsdom/level2/html.js:415:55)
at /usr/local/lib/node_modules/inliner/node_modules/jsdom/lib/jsdom/level2/html.js:56:15
at Object.check (/usr/local/lib/node_modules/inliner/node_modules/jsdom/lib/jsdom/level2/html.js:235:11)
at /usr/local/lib/node_modules/inliner/node_modules/jsdom/lib/jsdom/level2/html.js:251:12
at IncomingMessage.<anonymous> (/usr/local/lib/node_modules/inliner/node_modules/jsdom/lib/jsdom/level2/html.js:85:11)
at IncomingMessage.emit (events.js:81:20)
This is fixed @ 1.0.0.
I'm running via npm. Install went perfectly fine, but then when I run the inliner command I get this error: TypeError: Object #