Closed ghost closed 4 years ago
Because publicPath doesn't support patterns please read https://webpack.js.org/configuration/output/#outputpublicpath and https://webpack.js.org/guides/public-path/
@evilebottnawi but till now, It was working. Something was changed?
output.publicPath is option for webpack, not for file-loader
output.publicPath is option for webpack, not for file-loader
@evilebottnawi thanks for info, but till upgrade packages, the [ext] inside publicPath was working. How can I make the same without [ext]? I need to modify the path of files, which I will inject into html (with HtmlWebpackPlugin).
Expected Behavior
publicPath: ('[ext]' === 'js' || '[ext]' === 'css') ? "{$basePath}/dist/" : "./", => [ext] will return file extenstion
Actual Behavior
publicPath: ('[ext]' === 'js' || '[ext]' === 'css') ? "{$basePath}/dist/" : "./", => [ext] will return string '[ext]'
Code
https://gist.github.com/acqsk/45014a9cfd592a2b5bd9fbbbc8d94af3
How Do We Reproduce?
npm run build