dillon1000/react

Commit

[RFC] Use `accumulateInto` to save even more allocation

Trying to make the event a bit more performant for events.

Feel free to reject this because the API inevitably isn't great. It's good for perf though, and since we're only using `accumulate` in very restrained places, I think we're fine.

`accumulateInto` is `accumulate` that mutates more and allocates less. I kept `accumulate` in case we want that in the future.
Browse files
Changed paths6 files
First-parent comparison
M src/browser/eventPlugins/ResponderEventPlugin.js ModifiedM src/browser/ui/dom/components/LocalEventTrapMixin.js ModifiedM src/event/EventPluginHub.js ModifiedM src/event/EventPropagators.js ModifiedA src/utils/__tests__/accumulateInto-test.js AddedA src/utils/accumulateInto.js Added
Patch

Files changed

Rendering syntax-highlighted changes…