str = 'autocomplete=\\\"off\\\" name=\\\"composer_session_id\\\" value=\\\"1557423901\\\" \\\/>\\u003cinput type=\\\"hidden\\\" autocomplete=\\\"off\\\" name=\\\"is_explicit_place\\\" id=\\\"u436754_5\\\"';
or use this string
session_id\":1557423901,\"include_source\":\"web_composer\",\"allow_cities\":true},\"bootstrapEndpoint\":\"\\\/ajax\\\/places\\\/typeahead.php\"});},\"j4e8191ff7ff1878042874292\":function(){return new Typeahead(JSCC.get('j4e8191ff7ff1878042874291'), {node_id: \"u436754_1\",
i want that str.match() return value of composer_session_id which is "1557423901" and also the id of is_explicit_plac which is "u436754_5".
How to get "1557423901" and "u436754_5" using JavaScript regex.match() or split or else?
Note: It's guaranteed that name will precede value in each case.
matchfor this? Seemssplitis better suited here, merely split onid=andvalue=.