satazor / js-spark-md5

Lightning fast normal and incremental md5 for javascript
Do What The F*ck You Want To Public License
2.46k stars 469 forks source link

doesn't work in AMD environment #13

Closed Nek closed 11 years ago

Nek commented 11 years ago

I have a module defined like this

define(['jquery', 'md5', 'Bacon'], function ($, md5, Bacon) {
    console.log($);
    console.log(md5);
    console.log(Bacon);
}

Assuming the paths are right this logs me some code for $ and Bacon but undefined for md5. If I edit md5.js and change the line

define('spark-md5', factory);

to

define(factory);

the problem is gone.

ltanme commented 8 years ago

jquery and sparkMD5 is not defined?