Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
有什么办法可以摆脱这种冗余性?当你有几十个依赖项时,它看起来超级笨拙。
define(['a', 'exports'], function(a, exports) { });
是的,有另一种方法:
define(function(require) { var a = require('a') var exports = require('exports') .. })