You are viewing a single comment's thread. Return to all comments →
One-liner JavaScript solution:
console.log(input.match(/(\/\*[^\/]+\*\/|\/\/.+)/g).join("\n").split("\n").map(a=>a.trim()).join("\n"));
Seems like cookies are disabled on this browser, please enable them to open this website
Building a Smart IDE: Identifying comments
You are viewing a single comment's thread. Return to all comments →
One-liner JavaScript solution: