We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
目录
common/ - testcom.js test/ - init.js - index.js - index.css - gruntfile.js
KMC配置
kmc: { main:{ options: { packages: [ { name: 'common', path: '../', charset: 'utf-8' }, { name: 'test', path: '../', charset: 'utf-8' } ], depFilePath:'deps.js', comboOnly: true }, files: [ { src: './init.js' } ] }, page:{ options: { packages: [ { name: 'test', path: '../', charset: 'utf-8' } ] }, files: [ { src: './init.js', dest: "./init.combo.js" } ] } }
init.js代码
KISSY.add(function() { }, { requires: ['./index', './index.css'] })
index.js内容
KISSY.add(function(S, D, E, IO) { }, { requires: ['dom', 'event', 'ajax', 'common/testcom'] })
输出的结果: deps.js内容
KISSY.config('modules', { 'test/init': { requires: ['test/index']}, 'test/index': { requires: ['dom', 'event', 'ajax', 'common/testcom']} });
init.combo.js内容
/* combined files : common/testcom test/index test/init */ KISSY.add('common/testcom',function() { // testcom.js }); KISSY.add('test/index',function(S, D, E, IO) { }, { requires: ['dom', 'event', 'ajax', 'common/testcom'] }) KISSY.add('test/init',function() { }, { requires: ['./index'] })
index.combo.js中不要将common的文件内容打包进来。
The text was updated successfully, but these errors were encountered:
No branches or pull requests
目录
KMC配置
init.js代码
index.js内容
输出的结果:
deps.js内容
init.combo.js内容
期望结果
index.combo.js中不要将common的文件内容打包进来。
The text was updated successfully, but these errors were encountered: