Running Webpack with --display-error-detail I got some extra information:
/path/to/MyIncludedFile doesn't exist
/path/to/MyIncludedFile.webpack.js doesn't exist
/path/to/MyIncludedFile.web.js doesn't exist
/path/to/MyIncludedFile.js doesn't exist
/path/to/MyIncludedFile.json doesn't exist
because of that, I realised that Webpack wasn't looking for the correct extension, which in my case is .ts.
In order to solve that I modified my webpack.config.js adding the following:
resolve: {
extensions: ['.ts']
}
inside my module configuration. So to be more specific, my module webpack conf now look like this:
module.exports = [
{
entry: /* my entry config */
output: {
/* my output config */
},
module: {
loaders: [
{
test: /\.ts/,
loaders: ['ts-loader']
}
]
},
/* ... other stuff ... */
resolve: {
extensions: ['.ts']
}
},
/* ... other modules ... */
]