Quote:
Originally Posted by Demongornot
So if I understand, we can use a condition with "return" to return the data passed as argument in the function when the condition is true ?
|
Will create an array which contains only the elements which pass the test.
Quote:
Originally Posted by Demongornot
I would be more familiar with :
array.filter(word => word.toString().indexOf(host) > -1).reverse();
|
Looks like it is a ECMAScript 6 method. You can only use ECMAScript 5 (if I am correct) methods in eventscripter.