修复:webpack打包修复 (#21)

* 修复打包逻辑问题
This commit is contained in:
张敏 2017-04-26 18:02:19 +08:00 committed by GitHub
parent 237502c3ec
commit 6331645a51
4 changed files with 7 additions and 3 deletions

1
.gitignore vendored
View File

@ -4,6 +4,7 @@
.idea
.vscode
packages/**/lib
lib/
lib/*
!lib/index.js
!lib/style.css

View File

@ -1,6 +1,6 @@
var webpack = require('webpack');
var getPostcssPlugin = require('./utils/postcss_pipe');
var config = require('./webpack.config.js');
var config = require('./webpack.config.dev.js');
config.entry = {
'vant': './src/index.js'

View File

@ -1,7 +1,9 @@
var webpack = require('webpack');
var config = require('./webpack.config.js');
var config = require('./webpack.build.js');
config.output.filename = config.output.filename.replace(/\.js$/, '.min.js');
config.entry = {
'index': './src/index.js'
};
config.plugins = config.plugins.concat([
new webpack.optimize.UglifyJsPlugin({

View File

@ -4,6 +4,7 @@
"description": "有赞vue wap组件库",
"main": "lib/vant.js",
"style": "lib/vant-css/index.css",
"unpkg": "lib/index.js",
"files": [
"lib",
"src",