Svgs crash the app
Current Behavior
After upgrading from 18nx to 19 in React project I have this issue: Failed to execute 'createElement' on 'Document': The tag name provided ('http://localhost:4200/fintiba-logo.939a27c492f3b4a984045f1df5584f2b.svg') is not a valid name.
I checked if replace it with import { ReactComponent as Logo } from './logo.svg'; it works, But I don't want to change it everywhere.
Expected Behavior
After upgrading to latest NX version expect imports work as before.
GitHub Repo
No response
Steps to Reproduce
- migrate from nx 18 to 19.
- used import in 18nx as import Logo from '../../../assets/svg/fintiba-logo.svg';
Nx Report
Node : 20.3.1
OS : darwin-arm64
npm : 9.6.7
nx : 19.0.4
@nx/js : 19.0.4
@nx/jest : 19.0.4
@nx/linter : 19.0.4
@nx/eslint : 19.0.4
@nx/workspace : 19.0.4
@nx/cypress : 19.0.4
@nx/devkit : 19.0.4
@nx/eslint-plugin : 19.0.4
@nx/expo : 19.0.4
@nx/node : 19.0.4
@nx/react : 19.0.4
@nrwl/tao : 19.0.4
@nx/web : 19.0.4
@nx/webpack : 19.0.4
typescript : 5.3.3
Failure Logs
No response
Package Manager Version
No response
Operating System
- [X] macOS
- [ ] Linux
- [ ] Windows
- [ ] Other (Please specify)
Additional Information
No response
Can you show your webpack config? Or provide a small repo
This issue has been automatically marked as stale because more information has not been provided within 7 days. It will be closed in 21 days if no information is provided. If information has been provided, please reply to keep it active. Thanks for being a part of the Nx community! 🙏
This issue has been closed for more than 30 days. If this issue is still occuring, please open a new issue with more recent context.