-
Notifications
You must be signed in to change notification settings - Fork 2.8k
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
ISuggestionModel misused for PeoplePickers? #4195
Comments
@joschect for FYI as Pickers codeowner, @dzearing for FYI as we were just discussing the future of decorator usage, per @Markionium's suggested design. |
I like the suggestion. I'm pretty on board with anything that makes pickers cleaner. |
Rock on. @Markionium would you be willing to open a PR? |
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions to Fabric React! |
PR merged (#4569 ). Please open new issue if you are still having issues. |
When trying to add some additional types i ran into the following.
I tried adding a typedef to the
defaultProps
in the following snippet. I ran into the problem that thecreateGenericItem
does not use the same signature as the one expected by theBasePickerProps
The expected signature for the createGenericItem is the following.
The returned object should be an
ISuggestionModel
which has the following interface.However the function
createGenericItem
returns something wildly different, that does not have any properties in common with the expectedISuggestionModel
.It seems we do some juggling to make sure that the item use in the end is of the correct interface, but it seems we could do this somewhat cleaner.
The text was updated successfully, but these errors were encountered: