You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Dec 5, 2019. It is now read-only.
...the file is written in the correct folder but the path that is written into the file is relative to the base directory (I guess it's the output.path option) instead of the file. As an example I'm getting:
/*! For license information please see chunks/polyfill-url-search-params/index.123hash.js.LICENSE */
In production, this path is wrong because the relative directory to the LICENSE file, so it would be located in: http://example.com/chunks/polyfill-url-search-params/chunks/polyfill-url-search-params/index.123hash.js.LICENSE
If the current behavior is a bug, please provide the steps to reproduce.
What is the expected behavior?
I was expecting the path to be relative to the file it was extracted out of, in the same way the sourcemap comment is relative to it's base file. So I'd expect this comment:
/*! For license information please see index.9aa3a7a3fab51a749ce0.js.LICENSE */
One option would be to provide the source file path so I could do a manual path rewrite with a function for the filename option.
If this is a feature request, what is motivation or use case for changing the behavior?
As all the files are hosted in the same directory (file.123hash.js, file.123hash.js.map, file.123hash.js.LICENCE) it's necessary that the url that is found within the file is also relative to the path it is found in.
Please mention other relevant information such as the browser version, Node.js version, webpack version and Operating System.
Version: webpack 3.8.1
Do you want to request a feature or report a bug?
I'm not sure, it's probably a FR
What is the current behavior?
When using the
UglifyjsWebpackPlugin
with the following options......the file is written in the correct folder but the path that is written into the file is relative to the base directory (I guess it's the
output.path
option) instead of the file. As an example I'm getting:In production, this path is wrong because the relative directory to the
LICENSE
file, so it would be located in:http://example.com/chunks/polyfill-url-search-params/chunks/polyfill-url-search-params/index.123hash.js.LICENSE
If the current behavior is a bug, please provide the steps to reproduce.
What is the expected behavior?
I was expecting the path to be relative to the file it was extracted out of, in the same way the sourcemap comment is relative to it's base file. So I'd expect this comment:
One option would be to provide the source file path so I could do a manual path rewrite with a function for the
filename
option.If this is a feature request, what is motivation or use case for changing the behavior?
As all the files are hosted in the same directory (
file.123hash.js
,file.123hash.js.map
,file.123hash.js.LICENCE
) it's necessary that the url that is found within the file is also relative to the path it is found in.Please mention other relevant information such as the browser version, Node.js version, webpack version and Operating System.
Version: webpack 3.8.1
Wepback config:
This issue was moved from webpack/webpack#6059 by @evilebottnawi. Orginal issue was by @nirazul.
The text was updated successfully, but these errors were encountered: