-
-
Notifications
You must be signed in to change notification settings - Fork 8.4k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
perf(runtime-core): optimize the performance of getTypeIndex (#3206)
- Loading branch information
1 parent
c8df618
commit 2e50acf
Showing
1 changed file
with
1 addition
and
5 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
isSameType.bind(null, type) would be even faster than recreating the callback on iteration
You would need to switch the params in function signature though
I did some research before and turned out bind was 10 factor faster than higher order functions