-
-
Notifications
You must be signed in to change notification settings - Fork 645
Closed
Description
Do you want to request a feature or report a bug?
Bug
What is the current behavior?
webpack-cli init
Answer index.js to the question 'Which module will be the first to enter the application?'.
Then if you run webpack, fails with error:
ERROR in Entry module not found: Error: Can't resolve 'index.js' in '/Users/.../test-webpack'
What is the expected behavior?
- Should create a webpack config in which the entry name has been transformed similar to the way
output.pathis handled, e.g.
// instead of
module.exports = {
entry: 'index.js',
output: {
filename: '[name].bundle.js',
path: path.resolve(__dirname, 'dist')
}, ...
// should be
module.exports = {
entry: path.resolve(__dirname, 'index.js'),
output: {
filename: '[name].bundle.js',
path: path.resolve(__dirname, 'dist')
}, ...-
Ideally the question Yeoman asks should be more explicit about the input format it expects too, so I know to type
index.jsrather thanindex. -
It should possibly also have a default of
index.js? That might also help clarify the format too.
Please mention other relevant information such as the browser version, Node.js version, Operating System and programming language.
$ webpack-cli --version
1.3.3