Update README.md
给 components 添加短路径功能。
默认短路径不支持跨模块,如果要跨模块,请像这样配置 paths。
fis.config.set('settings.preprocessor.components.paths', { 'jquery': 'common:components/jquery/jquery.js' });
paths 也可以是 dir 如:
fis.config.set('settings.preprocessor.components.paths', { 'bootstrap': 'common:components/bootstrap/' });
这样 require('bootstrap/button.js') 的时候,实际上是 require('common:components/bootstrap/button.js')
require('bootstrap/button.js')
require('common:components/bootstrap/button.js')
版权所有:中国计算机学会技术支持:开源发展技术委员会 京ICP备13000930号-9 京公网安备 11010802032778号
fis-preprocessor-components
给 components 添加短路径功能。
默认短路径不支持跨模块,如果要跨模块,请像这样配置 paths。
paths 也可以是 dir 如:
这样
require('bootstrap/button.js')的时候,实际上是require('common:components/bootstrap/button.js')