From f342c54e5c23eb9a37606eb242e71ebade7ad1b0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20Jezierski?= Date: Sun, 13 Nov 2016 22:59:33 +0100 Subject: [PATCH] build fixes --- package.json | 7 +++---- webpack.config.js | 19 ++++++++----------- 2 files changed, 11 insertions(+), 15 deletions(-) diff --git a/package.json b/package.json index 640d0dd..ed146b6 100644 --- a/package.json +++ b/package.json @@ -1,10 +1,9 @@ { "name": "mdn-polyfills", - "version": "1.0.0", - "description": "MDN polyfills - Array.from, Array.find, Object.assign, ...", + "version": "2.0.0", + "description": "MDN polyfills", "scripts": { - "transpile": "babel ./src --out-dir ./dist", - "prepublish": "npm run transpile && webpack", + "prepublish": "webpack", "test": "ava" }, "repository": { diff --git a/webpack.config.js b/webpack.config.js index cf3eb23..9776596 100644 --- a/webpack.config.js +++ b/webpack.config.js @@ -1,11 +1,12 @@ const webpack = require('webpack'); -const path = require('path'); module.exports = { entry: { "Object.assign": "./src/Object.assign/index.js", "Array.prototype.find": "./src/Array.prototype.find/index.js", - "Array.prototype.from": "./src/Array.prototype.from/index.js" + "Array.prototype.from": "./src/Array.prototype.from/index.js", + "Array.prototype.filter": "./src/Array.prototype.filter/index.js", + "Array.prototype.forEach": "./src/Array.prototype.forEach/index.js" }, output: { filename: "[name].js" @@ -14,14 +15,10 @@ module.exports = { new webpack.optimize.UglifyJsPlugin() ], module: { - - loaders: [ - { - test: /\.js$/, - exclude: /node_modules/, - loader: 'babel' - } - ] - + loaders: [{ + test: /\.js$/, + exclude: /node_modules/, + loader: 'babel' + }] } };