The "Uncaught ReferenceError: parseNumbers is not defined" error is throw at this point in the generated bundle:
parseNumbers = function parseNumbers(str) {
if (!isNaN(str)) {
str = str % 1 === 0 ? parseInt(str, 10) : parseFloat(str);
}
return str;
};
I'm struggling with getting Hot Module Reloading to work, and this is the latest problem. Seems to me to be a Webpack problem, but who knows?
The bundle file builds ok without errors. Here is my webpack.config.js file:
var path = require('path');
var webpack = require('webpack');
var WebpackNotifierPlugin = require('webpack-notifier');
module.exports = {
context: path.join(__dirname, 'app'),
entry: [
'webpack-dev-server/client?http://localhost:3000',
'webpack/hot/only-dev-server',
path.join(__dirname, 'app/app.js')
//'app/app.js'
],
output: {
path: path.join(__dirname, 'built'),
filename: '[name].bundle.js'
//filename: './built.bundle.js'
},
plugins: [
new webpack.HotModuleReplacementPlugin(),
new WebpackNotifierPlugin()
],
module: {
loaders: [
{ test: /\.css$/, loader: "style!css" },
{ test: /\.jpe?g$|\.gif$|\.png$|\.svg$|\.woff$|\.ttf$|\.eot$/, loader: "url" },
{
test: /\.js$/,
loaders: ['react-hot', 'babel'],
include: path.join(__dirname, 'app')
}
]
}
};
What can I do to fix this? Thanks for any help.