Closed jamalsoueidan closed 11 years ago
@jamalsoueidan in your node code, you can force window.$ to be jquery
var window = $('body')[0]._ownerDocument._parentWindow;
window._$ = window.$;
window.$ = $;
but do this only if your code is rather hack-ish & you don't intend to maintain it, since _ownerDocument._parentWindow
is private & might change with jsdom versions.
I'm getting this error
$(function() { ^ TypeError: Property '$' of object [object DOMWindow] is not a function
I cannot change the site sourcecode.