-
• #2
I doubt it will be, and you can define your own function or just use:
var str = 'Hello planet earth, you are a great planet.'; var search = 'planet'; var lastIndex = (str.split('').reverse().join('').indexOf(search.split('').reverse().join('')) - str.length + search.length) * (-1)
Please test this, I haven't :P
-
• #3
Just added - it'll be in version 1.58 :)
-
• #4
Appreciated :)
-
• #5
@randunel: Hey, thanks. Since one can access Strings on a character level, one can basically implement anything. But given that this is a somehow common function, other people might also miss it. So, might help to have it directly included in the distribution.
Funnily enough I came across it in a function that actually did not need it :)
-Stev
Hey, lastIndexOf seems to be used now and then by some scripts, but is not supported yet. Will it be?
-Stev