-
Notifications
You must be signed in to change notification settings - Fork 2.7k
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
compose: adding mergeProps
utility to react-compose
#13360
compose: adding mergeProps
utility to react-compose
#13360
Conversation
…eat/create-options-resolver
…ate files, removing react-is usage which wasn't in the package.json, no need to pull an external dependency to check if we're a forwardref.
…fice-ui-fabric-react into feat/compose-cleanup
…eat/create-options-resolver # Conflicts: # packages/react-compose/src/mergeComposeOptions.ts # packages/react-compose/src/types.ts
…eat/create-options-resolver
resolve
callback to options to resolve conformance concernsresolve
callback to options
Perf Analysis
All results
Perf Analysis (Fluent)Perf comparison
Perf tests with no regressions
|
Co-authored-by: Makoto Morimoto <Humberto.Morimoto@microsoft.com>
…eat/create-options-resolver
…eat/create-options-resolver
…aring/office-ui-fabric-react into feat/create-options-resolver
… is not accurate any more.
I did some sleuthing with webpack bailouts to understand why the bundle size jumped so much.
|
I believe this is ready to go in. |
🎉 Handy links: |
🎉 Handy links: |
🎉 Handy links: |
* Updating typings. * Fixing the template variable names, splitting out utils.ts into separate files, removing react-is usage which wasn't in the package.json, no need to pull an external dependency to check if we're a forwardref. * Change files * Missed one merge conflict. * reducing changes * Update @fluentui-react-compose-2020-05-27-08-46-47-feat-compose-cleanup.json * pr feedback * more * Moving classname changes to separate branch * cleanup. * Change files * pass build * cleanup * pr updates. * updates * Updates to tests. * more tests, types, etc. * More tests. * Updating api * Updates resolve to be mergeProps, removes from the compose options, deletes unused code. * Rename * Updates to rename mapPropsToSlotProps. * Update @fluentui-react-compose-2020-05-27-12-54-51-feat-create-options-resolver.json * Update packages/react-compose/src/mergeProps.ts Co-authored-by: Makoto Morimoto <Humberto.Morimoto@microsoft.com> * fix. * fixes. * Change files * api updates. * renames * oi * Update to package.json * undo. * Button updates to address screener issues; private copy of mergeProps is not accurate any more. * Change files * Reduce bundle size by 3k by removing side effect code. * Change files * screener fix. Co-authored-by: Makoto Morimoto <Humberto.Morimoto@microsoft.com>
This PR splits out more of my draft PR, and adds a
mergeProps
helper to the compose package. This helper will help resolveslots
andslotProps
and effectively can replace theresolveSlotProps
that is nested withinmergeComposeOptions
. Expected usage:I have not removed the existing implementation so that the v0 code is not busted, but once this is in, that code can be updated.
I am going through the shorthand factory tests right now to validate I didn't miss any, and will be adding more tests to this PR but wanted to get this going sooner for early feedback.