1.0.1 • Published 4 years ago
upload-code-plugin v1.0.1
upload-code-plugin
打包完自动上传代码插件
杭州微客到测试栈自动上传代码的webpack插件
Installing
Using npm:
$ npm install upload-code-plugin
Example
// import
const uploadPlugin = require('./uploadCode-plugin');
module.exports = {
entry: 'index.js',
output: {
path: __dirname + '/dist',
filename: 'index_bundle.js'
},
plugins: [
// new
new uploadPlugin({...option})
]
}
//option
{
this.serverUrl = 'http://admin.tecqm.com'; //serve_url
this.loginApi = '/login/index'; //login_api
this.loginParams = { //login_params
account: 'admin',
password: '********'
};
this.uploadApi = '/System/upload'; //upload_api
this.uploadParams = { //upload_params
type: 2
};
}
by zhangbo http://www.wkddao.com
License
MIT