Add AMD support when define and define.amd detected
This commit is contained in:
parent
47304d29b4
commit
aa5556992c
@ -967,6 +967,8 @@ marked.parse = marked;
|
||||
|
||||
if (typeof module !== 'undefined') {
|
||||
module.exports = marked;
|
||||
} else if(typeof define === 'function' && define.amd) {
|
||||
define(function() { return marked; });
|
||||
} else {
|
||||
this.marked = marked;
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user