Created
October 26, 2017 17:34
-
-
Save dclarke-modus/bded71e5b1d31fa8b483746784462964 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//ERROR | |
ERROR in ./app/index.js | |
Module parse failed: /home/vagrant/Projects/com_oauth_manager/media/com_oauth_manager/js/com_oauthmanager/app/index.js Unexpected token (6:16) | |
You may need an appropriate loader to handle this file type. | |
| var App = require('./component/App'); | |
| | |
| ReactDOM.render(<App />, document.getElementById('oauth-manager')); | |
//WEBPACK.CONFIG.JS | |
const ExtractTextPlugin = require("extract-text-webpack-plugin"); | |
module.exports = { | |
entry : __dirname + '/app/index.js', | |
module : { | |
loaders: [ | |
{ | |
test: /\.js$/, | |
exclude: /node_modules/, | |
loader: 'babel-loader' | |
} | |
], | |
rules: [ | |
{ | |
test: /\.s?css$/, | |
use: ['style-loader', 'css-loader', 'sass-loader'], | |
} | |
] | |
}, | |
output: { | |
filename : 'bundled.js', | |
path : __dirname + '/build' | |
}, | |
watch: true, | |
watchOptions: { | |
aggregateTimeout: 300, | |
poll: 200 | |
}, | |
plugins: [ | |
new ExtractTextPlugin("styles.css") | |
] | |
}; | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment