Regex needed that will split string based on following criteria
I need to split string based on regex in javascript. The format of the string is as follows 'publication_or_portfolio_links.0.link'
I need to split based on '.index.' (note dot before and after the inex) i.e. the result should be 'publication_or_portfolio_links' and 'link' i.e. '.0.' has been removed.
I would be thankful if some help me.