所以我使用 yeoman init 创建了一个项目,它使用了 requirejs,我希望用 almondjs 替换 requirejs 以使其加载更快。我怎样才能做到这一点?
AlmondJS 在这里:https ://github.com/jrburke/almond
RequireJS 在这里:http ://requirejs.org/
约曼:http: //yeoman.io/
在 Gruntfile.js 中唯一提到 require.js 是:
// rjs configuration. You don't necessarily need to specify the typical
// `path` configuration, the rjs task will parse these values from your
// main module, using http://requirejs.org/docs/optimization.html#mainConfigFile
//
// name / out / mainConfig file should be used. You can let it blank if
// you're using usemin-handler to parse rjs config from markup (default
// setup)
rjs: {
// no minification, is done by the min task
optimize: 'none',
baseUrl: './scripts',
wrap: true,
name: 'main'
},