This repository was archived by the owner on Apr 14, 2020. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 1
Change util methods for standard ES6 ones #1
Copy link
Copy link
Open
Description
There are a lot of "util" methods present in current Knockout code that are part of the ES6 definitions.
They are also implemented in shims, as Babel presets for example. So there is no more need to implement them by our side. Just use the ES6 definition and let the transpilers do the rest.
We can use them directly or adapt the inner code to reuse them, but not reimplementing the wheel.
I'll list all of them here:
Array
- arrayForEach https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/forEach
- arrayIndexOf
- arrayFirst https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/some
- arrayMap https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/map
- arrayFilter https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/filter
- makeArray https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/from
Function
- bind remove it
Object
Metadata
Metadata
Assignees
Labels
No labels