Browse Source

use webpack 2

pull/342/head
Guillaume Vincent 8 years ago
parent
commit
1a69992d01
4 changed files with 9696 additions and 29 deletions
  1. +9662
    -3
      dist/lesspass.css
  2. +15
    -15
      dist/lesspass.js
  3. +9
    -4
      package.json
  4. +10
    -7
      webpack.config.js

+ 9662
- 3
dist/lesspass.css
File diff suppressed because it is too large
View File


+ 15
- 15
dist/lesspass.js
File diff suppressed because it is too large
View File


+ 9
- 4
package.json View File

@@ -22,7 +22,7 @@
"bootstrap": "^4.0.0-alpha.4", "bootstrap": "^4.0.0-alpha.4",
"clipboard": "^1.5.12", "clipboard": "^1.5.12",
"css-loader": "^0.25.0", "css-loader": "^0.25.0",
"extract-text-webpack-plugin": "^1.0.1",
"extract-text-webpack-plugin": "^2.0.0-beta.4",
"file-loader": "^0.9.0", "file-loader": "^0.9.0",
"font-awesome": "^4.6.3", "font-awesome": "^4.6.3",
"hint.css": "^2.3.2", "hint.css": "^2.3.2",
@@ -42,12 +42,17 @@
"vue-loader": "^9.5.1", "vue-loader": "^9.5.1",
"vue-router": "^2.0.0", "vue-router": "^2.0.0",
"vuex": "^2.0.0", "vuex": "^2.0.0",
"webpack": "^1.13.2",
"webpack-dev-server": "^1.16.2"
"webpack": "^2.1.0-beta.25",
"webpack-dev-server": "^2.1.0-beta.9"
}, },
"babel": { "babel": {
"presets": [ "presets": [
"es2015",
[
"es2015",
{
"modules": false
}
],
"stage-2" "stage-2"
], ],
"plugins": [ "plugins": [


+ 10
- 7
webpack.config.js View File

@@ -10,21 +10,25 @@ module.exports = {
filename: 'lesspass.js' filename: 'lesspass.js'
}, },
resolve: { resolve: {
extensions: ['', '.json', '.js', '.vue'],
extensions: ['.json', '.js', '.vue'],
alias: { alias: {
jquery: 'jquery/src/jquery' jquery: 'jquery/src/jquery'
} }
}, },
resolveLoader: {
root: path.join(__dirname, 'node_modules')
},
module: { module: {
loaders: [
rules: [
{test: /\.vue$/, loader: 'vue-loader'}, {test: /\.vue$/, loader: 'vue-loader'},
{test: /\.js$/, include: [path.resolve(__dirname, './src')], loader: 'babel-loader'}, {test: /\.js$/, include: [path.resolve(__dirname, './src')], loader: 'babel-loader'},
{test: /\.json/, loader: 'json-loader'}, {test: /\.json/, loader: 'json-loader'},
{test: /\.(png|jpg|jpeg|gif)$/, loader: 'file-loader?name=[name].[ext]',}, {test: /\.(png|jpg|jpeg|gif)$/, loader: 'file-loader?name=[name].[ext]',},
{test: /\.css$/, loader: ExtractTextPlugin.extract('style-loader', 'css-loader', {publicPath: ''})},
{
test: /\.css$/,
loader: ExtractTextPlugin.extract({
fallbackLoader: 'style-loader',
loader: 'css-loader',
publicPath: ''
})
},
{test: /\.woff(\?v=\d+\.\d+\.\d+)?$/, loader: 'url-loader?limit=8192&mimetype=application/font-woff'}, {test: /\.woff(\?v=\d+\.\d+\.\d+)?$/, loader: 'url-loader?limit=8192&mimetype=application/font-woff'},
{test: /\.woff2(\?v=\d+\.\d+\.\d+)?$/, loader: 'url-loader?limit=8192&mimetype=application/font-woff'}, {test: /\.woff2(\?v=\d+\.\d+\.\d+)?$/, loader: 'url-loader?limit=8192&mimetype=application/font-woff'},
{test: /\.ttf(\?v=\d+\.\d+\.\d+)?$/, loader: 'url-loader?limit=8192&mimetype=application/octet-stream'}, {test: /\.ttf(\?v=\d+\.\d+\.\d+)?$/, loader: 'url-loader?limit=8192&mimetype=application/octet-stream'},
@@ -48,7 +52,6 @@ if (process.env.NODE_ENV === 'production') {
module.exports.devtool = false; module.exports.devtool = false;
module.exports.plugins = (module.exports.plugins || []).concat([ module.exports.plugins = (module.exports.plugins || []).concat([
new webpack.optimize.DedupePlugin(), new webpack.optimize.DedupePlugin(),
new webpack.optimize.OccurrenceOrderPlugin(),
new webpack.IgnorePlugin(/^\.\/locale$/, /moment$/), new webpack.IgnorePlugin(/^\.\/locale$/, /moment$/),
new webpack.optimize.UglifyJsPlugin({ new webpack.optimize.UglifyJsPlugin({
compress: { compress: {


Loading…
Cancel
Save