Regex para comentarios JavaScript
// Playground :
https://www.regextester.com/93814
// code :
/(/\*([^*]|[\r\n]|(\*+([^*/]|[\r\n])))*\*+/)|(//.*)/igm
night owl
// Playground :
https://www.regextester.com/93814
// code :
/(/\*([^*]|[\r\n]|(\*+([^*/]|[\r\n])))*\*+/)|(//.*)/igm