4.7.4 • Published 5 months ago

yyl-seed-gulp-requirejs v4.7.4

Weekly downloads
9
License
ISC
Repository
github
Last release
5 months ago

yyl-seed-gulp-requirejs

yyl 构建种子 - gulp-requirejs

SDK

seed.name

/**
 * @return {String} seed 包名称
 */
seed.name

seed.version

/**
 * @return {String} seed 包版本
 */
seed.version

seed.path

/**
 * @return {String} seed 所在目录
 */
seed.path

seed.example

/**
 * @return {Array} seed example list
 */
seed.path

seed.optimize()

/**
 * @param  {Object} config       配置文件
 * @param  {Object} config.alias                  作用域
 * @param  {String} config.alias.commons          公用组件地址
 * @param  {String} config.alias.globalcomponents 公用 components 目录
 * @param  {String} config.alias.globallib        公用 components 目录
 * @param  {String} config.alias.root             输出目录中 到 html, js, css, image 层 的路径
 * @param  {String} config.alias.revRoot          rev 输出内容的相对地址
 * @param  {String} config.alias.destRoot         dest 地址
 * @param  {String} config.alias.srcRoot          src 地址
 * @param  {String} config.alias.dirname          项目根目录
 * @param  {String} config.alias.jsDest           js 输出地址
 * @param  {String} config.alias.jslibDest        js lib 输出地址
 * @param  {String} config.alias.htmlDest         html 输出地址
 * @param  {String} config.alias.cssDest          css 输出地址
 * @param  {String} config.alias.imagesDest       images 输出地址
 * @param  {String} config.alias.revDest          assets 输出地址
 * @param  {String} config.alias.tplDest          tpl 输出地址
 * @param  {String} projectPath                   构建项目所在目录
 * @return Promise<opzer> opzer                         压缩实例
 */
seed.optimize({ config, root })

opzer

/**
 * @param  {Object}  op 参数
 * @param  {Boolean} op.isCommit 执行压缩
 * @param  {Boolean} op.remote   映射远程
 * @return {Object}  ctrler      操作句柄
 */
opzer.watch(op)
opzer.watchAll(op)
opzer.all(op)
opzer.js(op)
opzer.css(op)
opzer.html(op)
opzer.tpl(op)
opzer.images(op)

ctrler.on()

/**
 * @param {String} eventName 需要监听的事件,目前有
 *                           - onOptimize 对应 fn(file)
 *                           - finished   对应 fn(taskName)
 *                           - msg        对应 fn(type, argv)
 *                           - clear      对应 fn()
 *                           - start      对应 fn(taskName)
 */
opzer.on(eventName, fn)

ctrler.off()

/**
 * @param  {String} eventName 要解除绑定的 eventName, 
 *                            不填则全部都解绑
 * @return {Void}
 */
opzer.off(eventName)

ctrler.trigger()

/**
 * @param {String} eventName 需要触发的事件
 * @param {Array}  argv      参数
 */
opzer.trigger(eventName, argv)
4.7.4

5 months ago

4.7.3

5 months ago

4.7.2

5 months ago

4.7.1

7 months ago

4.7.0

7 months ago

4.6.0

12 months ago

4.5.0

12 months ago

4.4.0

12 months ago

4.3.0

12 months ago

4.2.0

12 months ago

4.1.0

12 months ago

4.0.0

1 year ago

4.0.0-beta4

1 year ago

4.0.0-beta5

1 year ago

4.0.0-beta3

1 year ago

4.0.0-beta1

1 year ago

4.0.0-beta2

1 year ago

3.0.1

1 year ago

3.0.0

1 year ago

2.6.1-beta2

2 years ago

2.6.1-beta1

2 years ago

2.6.0

2 years ago

2.5.8

2 years ago

2.5.7

2 years ago

2.5.6

2 years ago

2.5.5

2 years ago

2.5.4

2 years ago

2.5.3

2 years ago

2.5.2

2 years ago

2.5.1

2 years ago

2.5.0

2 years ago

2.4.5

2 years ago

2.4.4-beta2

2 years ago

2.4.4-beta1

2 years ago

2.4.4

2 years ago

2.4.3

2 years ago

2.4.2

2 years ago

2.4.1

2 years ago

2.4.0

2 years ago

2.2.0

2 years ago

2.1.1

2 years ago

2.1.0

2 years ago

2.0.1

2 years ago

2.0.0

2 years ago

1.0.8

3 years ago

1.0.7

3 years ago

1.0.6

3 years ago

1.0.5

3 years ago

1.0.4

3 years ago

1.0.3

3 years ago

1.0.2

3 years ago

1.0.1

3 years ago

1.0.0

3 years ago