1.0.2 • Published 3 years ago

yyl-env-pop-webpack-plugin v1.0.2

Weekly downloads
17
License
MIT
Repository
github
Last release
3 years ago

yyl-env-pop-webpack-plugin

用于注入 entry 下的 pop 弹窗插件, 用来方便调试时识别当前环境是线上还是本地

install

npm i yyl-env-pop-webpack-plugin --save

USAGE

// webpack.config.js
const YylEnvPopWebpackPlugin = require('yyl-env-pop-webpack-plugin')
module.exports = {
  plugins: [
    new YylEnvPopWebpackPlugin({
      text: 'hello world',
      duration: 3000
      enable: true
    })
  ]
}

ts

直接看 types 吧

export interface YylEnvPopWebpackPluginOption {
  /** 是否启用 */
  enable?: boolean
  /** 显示文本 */
  text?: string
  /** 显示时间 */
  duration?: number
  /** 过滤 true - 添加 js, false - 跳过 */
  filter?: (name: string) => boolean
}
export interface DefinePluginOption {
  [key: string]: string | number
}
1.0.2

3 years ago

1.0.1

3 years ago

1.0.0

3 years ago

0.3.0

3 years ago

0.3.1

3 years ago

0.2.0

4 years ago

0.1.5

4 years ago

0.1.4

4 years ago

0.1.2

4 years ago

0.1.3

4 years ago

0.1.1

4 years ago

0.1.0

4 years ago