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
Compile Issue importing react-core.css in create-react-app project #5813
Comments
What's your use case for |
Tanks for the super-fast turnaround. If I only import |
@jimmyfm Make sure you |
Importing only Above you can see what I meant by "it doesn't look right without importing both css". |
Something is likely misconfigured in your app. You can see importing the base.css works fine in codesandbox. That UMD file is a reexport of |
The situation is more clear now. I will dig deeper into similar issues like #5650 then report back. |
Thanks for the codesanbox example, it provided the perfect environment to try and replicate the issue we are having. Eventually I succeeded by moving your code into a separate component. |
This ticket started from a wrong use of PF css then veered into something totally different. |
Importing
@patternfly/react-core/dist/umd/react-core.css
causes a compile error due to a brokenurl(...)
in the css.Please provide the steps to reproduce. Feel free to link CodeSandbox or another tool.
To replicate you can simply initialize a new create-react-app:
Add the css imports to
App.js
Running the build will show the error
Is this a bug or enhancement? If this issue is a bug, is this issue blocking you or is there a work-around?
I'd call this a bug, the images are effectively at the wrong path.
To get our code to compile we had to change the content of
react-core.css
replacing all the instances ofurl("../../assets/images/
withurl("../styles/assets/images/
as shown below.What is your product and what release version are you targeting?
We are currently running on 4.97.2, trying to upgrade to 4.121.1 to roll in the Select.onFilter fixes.
The text was updated successfully, but these errors were encountered: