I would like to replace the simple quotes in a string but not the escaped ones (in JavaScript). For example I want this string:
'Hello there! I\'m \'Doug\''
To become:
"Hello there! I\'m \'Doug\'"
NOTE: I made a lots of research and test (e.g on regex101.com) and found some things such as Regular expression to match a line that doesn't contain a word? but still can't figure out how to build a proper regex.
THINGS I TRIED:
- /[^\\]'/g
- /\\{0}'/g
- /[\\]{0}'/g
- ...
 
     
     
     
     
    