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
This issue is quite tricky to even report and I understand if you just close it as "cannot reproduce". I even thought about not opening this issue as it is quite hard to explain. But it may be somewhat helpful for others, so I will do my best to explain the problem.
That seems like a correct list of paths to look for libs, but the real problem is that I am doing build within nested subfolder which has it's own node_modules inside
I do not know too much about writing babel transforms, but I assume it may provide some context similar to cwd() from where files/libs need to be searched
I did not check but very much certain same problem would happen if I am to use global installation of babel/babel-plugin-css-modules-transform, because it would resolve to a babel-plugin-css-modules-transform folder in node directory and not the app one.
For the moment my only solution would be to not import css from a package directly, but update package so it exports css, because if paths are relative, this transform works ok.
The text was updated successfully, but these errors were encountered:
This issue is quite tricky to even report and I understand if you just close it as "cannot reproduce". I even thought about not opening this issue as it is quite hard to explain. But it may be somewhat helpful for others, so I will do my best to explain the problem.
The issue is in this function
requireCssFile
https://github.com/michalkvasnicak/babel-plugin-css-modules-transform/blob/master/src/index.js#L52-L72
I've added to the start of it
And I am getting this
That seems like a correct list of paths to look for libs, but the real problem is that I am doing build within nested subfolder which has it's own
node_modules
insideThis is what I would expect instead (check with just node, not going through the build loop)
I do not know too much about writing babel transforms, but I assume it may provide some context similar to
cwd()
from where files/libs need to be searchedI did not check but very much certain same problem would happen if I am to use global installation of babel/babel-plugin-css-modules-transform, because it would resolve to a babel-plugin-css-modules-transform folder in node directory and not the app one.
For the moment my only solution would be to not import
css
from a package directly, but update package so it exports css, because if paths are relative, this transform works ok.The text was updated successfully, but these errors were encountered: