-
-
Notifications
You must be signed in to change notification settings - Fork 256
revert(index): context
takes precedence over issuer.context
(options.useRelativePath
)
#260
Conversation
…ions.useRelativePath`) This reverts commit 3b071f5
context
takes precedence over issuer.context
(`opt…context
takes precedence over issuer.context
(options.useRelativePath
)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
👍
@michael-ciniawsky need ping someone who have this bug and tests this branch |
I'm afraid it does not restore the behavior that was in 1.1.7. Tested with issue reproduction repository (https://github.com/zemadz/file-loader-relative-path-minimum-repro) and my actual project that uses file-loader for CSS generation. |
@zemadz The following seems to work {
test: /\.(png)$/,
use: [
{
loader: 'file-loader',
options: {
name: '[name].[ext]',
// outputPath: paths.build,
useRelativePath: true
}
}
]
}
{
test: /\.(png)$/,
use: [
{
loader: 'file-loader',
options: {
name: '[name].[ext]',
outputPath (url) {
return 'test/' + url
}
useRelativePath: true
}
}
]
}
Your're getting something like this with this patch applied atm right?
|
With config:
I get the expected files at With the current pull request the following produces exactly the same output as the previous config:
|
@zemadz The export points to the destination of the outputted file ? Can you explain the use case or how this currently breaks an application of yours ? |
I'm using Webpack for compiling SASS. The idea is that there is a I've made an example with my use case (https://github.com/zemadz/file-loader-relative-path-css-repro). There are three branches |
This PR fixes the direct regression introduced in 3b071f5 @zemadz I will take checkout your second example soon, but due to |
Issues