Generation

generate functionTue, 01 Aug 2023

regex pattern extract the opti-id <novel-li opti-id="aaa">

Script let str = '<novel-li opti-id="aaa"></novel-li>'; str.match(/[^[0-9a-zA-Z](?<=opti-id=")(\w*)(?=")]/gi)[0];

Questions about programming?Chat with your personal AI assistant