Skip to content
This repository has been archived by the owner on Jul 22, 2024. It is now read-only.

Commit

Permalink
Merge pull request #42 from wangyateng/master
Browse files Browse the repository at this point in the history
添加一个amd条件,避免 define出错
  • Loading branch information
贤心 authored Feb 25, 2017
2 parents 70cb698 + 9b7b93f commit 896c733
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/layer.js
Original file line number Diff line number Diff line change
Expand Up @@ -1227,7 +1227,7 @@ window.layui && layui.define ? (
exports('layer', layer);
})
) : (
typeof define === 'function' ? define(['jquery'], function(){ //requirejs加载
(typeof define === 'function' && define.amd) ? define(['jquery'], function(){ //requirejs加载
ready.run(window.jQuery);
return layer;
}) : function(){ //普通script标签加载
Expand All @@ -1236,4 +1236,4 @@ window.layui && layui.define ? (
}()
);

}(window);
}(window);

0 comments on commit 896c733

Please # to comment.