Icon in initValue instead of a string
See original GitHub issueWould it be possible to set an icon as initialValue? A few months ago, thanks to your help, I was able to put it in the drop-down list but now I also need it in initValue. It works but an warning appears…
Warning: Failed prop type: Invalid prop initValue
of type object
supplied to ModalSelector
, expected string
.
Issue Analytics
- State:
- Created 4 years ago
- Comments:5 (3 by maintainers)
Top Results From Across the Web
How to dynamically use icon in a React app based on a string ...
It's simple: <AComponent icon={stringVariable === "icon1" ? Icon1 : Icon2}/>.
Read more >Flutter Dropdown Button hint text and initial value
It shows an empty string and a user can't change the value because it is disabled. ... Set hint text instead of initial...
Read more >Combining dynamic member lookup with key paths
... members — but this time using a KeyPath , rather than a String : ... private(set) var value: Value init(value: Value) {...
Read more >List of icons - Iconify Documentation
To prevent user apps from breaking, icons are never deleted, they are marked as hidden instead, but still can be used in apps....
Read more >How to Use Icons - Creating a GUI With Swing
public ThumbnailAction(Icon photo, Icon thumb, String desc){ displayPhoto ... load a placeholder instead thumbAction = new ThumbnailAction(placeholderIcon, ...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
The warning should be a simple fix. The propType needs to change to accept either a string or object.
Looking through the code, I’m surprised that an icon works for
initValue
. Would you mind posting a code snippet?Fork this project, make the changes to the code & Readme, then create a pull request. https://help.github.com/en/articles/creating-a-pull-request