Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

loader loses paths to source files in source map #1064

Closed
alexhisen opened this issue Apr 1, 2020 · 4 comments
Closed

loader loses paths to source files in source map #1064

alexhisen opened this issue Apr 1, 2020 · 4 comments

Comments

@alexhisen
Copy link

When css-loader calls postcss with an existing source map previously generated by postcss-loader, the resulting source map ends up with just the file name for sources without any paths. If there are then collisions of this file name with other same-named files in other directories, only one of these source maps ends up being retained.

This is particularly noticeable for the react-toolbox project which has about a dozen files all named theme.modules.css in different directories.

See https://github.com/alexhisen/mobx-forms-demo project for example config, etc. Note it's currently set up to use a fork with a workaround in #1053, so it doesn't exhibit the problem any more.

@alexander-akait
Copy link
Member

Thanks, I will look at that in near future

@alexander-akait
Copy link
Member

alexander-akait commented Apr 6, 2020

@alexhisen I will try your repo, but looks it doesn't work, I have white screen with a lot of errors in console, can you provide steps to reproduce? I used invalid url

@alexander-akait
Copy link
Member

Can you provide places where source maps broken (maybe screenshots), yes, right now it use absolute paths (it is bad for production, we are working on it)

@alexander-akait
Copy link
Member

Yep, looks duplicate, here the original issue #622, solution #622 (comment), feel free to leave feedback, we will try to fix it ASAP

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants