Javascript Regex: how to remove string before > and including >
- by Kim Jong Woo
I have a string like so
item[3]>something>another>more[1]>here
hey>this>is>something>new
.
.
.
I would like to produce the following for each iteration indicated by each new line
item[3]>something>another>more[1]>here
something>another>more[1]>here
another>more[1]>here
more[1]>here
here
Another example:
hey>this>is>something>new
this>is>something>new
is>something>new
something>new
new
I would like a regex or some way to incrementally remove the furthest left string up to .