JSFiddle - React, Tailwind, and code Playground
JavaScript
var x = 'product.time("string1","string2")';
var regex = /*.\(("|'*."|')\)*./g
var rez = regex.exec(x);
var x = 'product.time("string1","string2")';
var regex = /*.\(("|'*."|')\)*./g
var rez = regex.exec(x);