An AMD adaptable jQuery, which address the problem that AMD do not have a inherent window with a document. A creation of a mockup of window with a document is needed and handled.
npm install jquery-amd
Follow the instruction of the environments you are using.
var jq = require('jquery-amd');
var window = ... // use some window and dom mockup tool, like NDjs, jsdom etc.
var $ = jq(window);define(['jquery'], function(jq){
...
var window = ...; // use some window and dom mockup tool, like NDjs, jsdom etc.
var $ = jq(window);
...
});- Jianwei Liu
jquery-amd is released under the MIT license.