Echo JS 0.11.0

<~>
jaleksic 1611 days ago. link 2 points
Since you don't support objects as in e.g `classnames({ isActive })`, I guess you might improve performance a little by using `typeof arg === 'string'` instead of the more expensive `Array.isArray(arg)` call.

Replies

troy-tae 1611 days ago. link 2 points
I tested many of case and it seems property check is cheaper than typeof check.
So I confirmed all of method of Array.
And it seems `pop` is shortest method name.
Now I check `pop` instead of isArray.
If you have any other idea, please notice me!
Thank you again :)
troy-tae 1611 days ago. link 1 point
Yes you're right.
It seems Array.isArray compare with Array.prototype and that work is expensive!
Let me try several case and I'll try to find what is the best code.
Thank you :)