Skip to content

Commit

Permalink
refactor(config): rename configs
Browse files Browse the repository at this point in the history
Signed-off-by: Will Soto <[email protected]>
  • Loading branch information
willsoto committed Aug 13, 2016
1 parent f28748c commit 71d34b2
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 24 deletions.
17 changes: 3 additions & 14 deletions config/webpack.config.dev.js → config/webpack.dev.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
const webpack = require('webpack');

const helpers = require('./helpers');

const IS_PROD = process.argv.indexOf('-p') > -1;

module.exports = {
Expand All @@ -15,10 +13,7 @@ module.exports = {
preLoaders: [{
test: /\.ts$/,
loader: 'tslint',
include: [
helpers.root('src'),
helpers.root('demo')
],
exclude: /node_modules/,
query: {
emitErrors: false,
failOnHint: false
Expand All @@ -27,17 +22,11 @@ module.exports = {
loaders: [{
test: /\.ts$/,
loader: 'ts',
include: [
helpers.root('src'),
helpers.root('demo')
]
exclude: /node_modules/
}, {
test: /\.json$/,
loader: 'json',
include: [
helpers.root('src'),
helpers.root('demo')
]
exclude: /node_modules/
}]
},
resolve: {
Expand Down
10 changes: 2 additions & 8 deletions config/webpack.config.dist.js → config/webpack.dist.js
Original file line number Diff line number Diff line change
Expand Up @@ -36,10 +36,7 @@ module.exports = {
preLoaders: [{
test: /\.ts$/,
loader: 'tslint',
include: [
helpers.root('src'),
helpers.root('demo')
],
exclude: /node_modules/,
query: {
emitErrors: true,
failOnHint: true
Expand All @@ -48,10 +45,7 @@ module.exports = {
loaders: [{
test: /\.ts$/,
loader: 'ts',
include: [
helpers.root('src'),
helpers.root('demo')
],
exclude: /node_modules/,
// Currently broken on 0.8.2
// https://github.com/TypeStrong/ts-loader/issues/186
query: {
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
"scripts": {
"start": "webpack-dev-server",
"build:demo": "webpack -p",
"build:dist": "webpack --config ./config/webpack.config.dist.js",
"build:dist": "webpack --config ./config/webpack.dist.js",
"postbuild:dist": "uglifyjs dist/angular2-chartist.js --compress --mangle --screw-ie8 -o dist/angular2-chartist.min.js",
"test": "karma start",
"test:watch": "karma start --auto-watch --no-single-run",
Expand Down
2 changes: 1 addition & 1 deletion webpack.config.js
Original file line number Diff line number Diff line change
@@ -1 +1 @@
module.exports = require('./config/webpack.config.dev');
module.exports = require('./config/webpack.dev');

0 comments on commit 71d34b2

Please sign in to comment.