Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Webpack
  • Loading branch information
Juan Cazala committed Aug 7, 2016
1 parent 8eac4b5 commit 5e95fdf
Show file tree
Hide file tree
Showing 4 changed files with 23 additions and 1 deletion.
1 change: 1 addition & 0 deletions .gitignore
@@ -1 +1,2 @@
node_modules
dist
7 changes: 6 additions & 1 deletion package.json
Expand Up @@ -4,6 +4,8 @@
"description": "javascript universal app",
"main": "index.js",
"scripts": {
"build": "webpack --config webpack.config.js",
"start": "node dist/bundle.js",
"test": "echo \"Error: no test specified\" && exit 1"
},
"keywords": [
Expand All @@ -12,5 +14,8 @@
"app"
],
"author": "Juan Cazala",
"license": "MIT"
"license": "MIT",
"devDependencies": {
"webpack": "^1.13.1"
}
}
1 change: 1 addition & 0 deletions src/index.js
@@ -0,0 +1 @@
console.log('hello world')
15 changes: 15 additions & 0 deletions webpack.config.js
@@ -0,0 +1,15 @@
var webpack = require('webpack')
var path = require('path')
module.exports = {
context: __dirname,
entry: './src/index.js',
output: {
path: path.resolve('dist'),
filename: 'bundle.js',
},
plugins: [ new webpack.NoErrorsPlugin() ],
resolve: {
extensions: ['', '.js', '.json'],
modulesDirectories: ['.', 'src', 'node_modules']
}
}

0 comments on commit 5e95fdf

Please sign in to comment.