webpack / loader-runner

Runs (webpack) loaders
MIT License
302 stars 60 forks source link

loadLoader path fix #57

Closed sidverma32 closed 3 years ago

sidverma32 commented 3 years ago

Issue resolved in this PR: 13339

sokra commented 3 years ago

This must be fixed in webpack/webpack and not here

sokra commented 3 years ago

I think this need to be added here: https://github.com/webpack/webpack/blob/0b3886654a1a680eef88a5501bcab81488e0f757/lib/NormalModuleFactory.js#L970 resp. https://github.com/webpack/webpack/blob/0b3886654a1a680eef88a5501bcab81488e0f757/lib/NormalModuleFactory.js#L97-L112

Use const { parseResource } = require("./util/identifier"); to parse the result from resolving within identToLoaderRequest into path, query and fragment.

fragment need to be added to LoaderItem and can be returned from identToLoaderRequest. loader-runner already accepts that as argument. path -> loader query -> options fragment -> fragment