Timeline for Tips for Golfing in ECMAScript 6 and above
Current License: CC BY-SA 3.0
4 events
when toggle format | what | by | license | comment | |
---|---|---|---|---|---|
Feb 11, 2016 at 7:49 | comment | added | Cyoce |
Quick reference thing: fun`foo${1}bar${2}baz is equivalent to calling fun(["foo","bar","baz"],1,2)
|
|
Feb 10, 2016 at 19:17 | comment | added | Cyoce |
Be warned, this actually passes an array. fun`string` is the same as fun(["string"]) , not fun("string") . This is fine for functions that cast to string, like alert , but for others this could cause issues. For more information see the MDN article
|
|
Jun 25, 2015 at 11:53 | history | edited | Optimizer | CC BY-SA 3.0 |
added 27 characters in body
|
Jun 25, 2015 at 11:50 | history | answered | Downgoat | CC BY-SA 3.0 |