Comments (3)
That's a known issue with Next. Version 4 of component is old, it was designed many years ago and based on classes. Next does not support class based components.
There are several solutions:
- Update to version 5. You can install it by installing
@iconify/react@next
- Use web component
@iconify-icon/react
- Wrap version 4 in client only file.
from iconify.
Thanks for pointing out these solutions. Maybe we can add this information to the documentation to help others facing the same issue.
from iconify.
Forgot to close this issue.
Version 5 has been published as stable, so installing @iconify/react
will install new version that works with Next.js (sort of... see icon component docs)
from iconify.
Related Issues (20)
- 在uniapp中显示不出来图标 HOT 1
- @iconify/tailwind can't use underline HOT 3
- Opacity on icons HOT 1
- Feat: Type definition for all icon names HOT 1
- Icon toggles visibility when scrolled in/out of viewport - observer="false" does not work? HOT 7
- `@iconify-icon/react` prop `observe` didn't work HOT 2
- finding the "real corner" of an svg HOT 2
- Prefers reduced motion with transitions HOT 6
- I can't tell why is this happening HOT 9
- Npm install broken for 1.0.0 HOT 1
- Allows adding additional `attributes` when using `getIconCSS` HOT 5
- Plugin generates a lot of repeated CSS code HOT 2
- Unexpected element: <text> HOT 2
- Iconset request: Fluentui Emoji HOT 1
- ESM import issues HOT 6
- please add information about attribute `observer` and `noobserver` in the offcial site document HOT 1
- How do you guarantee icons don't change HOT 3
- Iconify - Definitely the easiest! Why not the fastest? HOT 6
- Feature Request: A SDK to pick icons
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from iconify.