2 ms·
It’s an old trick for pleasant-ish multi-line strings from before node/JavaScript had `backticks`. You can stringify the function and parse the string out of th
by maxwellg 3y ago
It’s an old trick for pleasant-ish multi-line strings from before node/JavaScript had `backticks`. You can stringify the function and parse the string out of the embedded comment.
- hombre_fatal 3y agoWe used to use a library (multiline) to write SQL strings in Node. const str = multiline(()=>{/* <!doctype html> <html> <body> <h1> unicorns</h1> </body> </html> */}); https://www.npmjs.com/package/multiline https://www.npmjs.com/package/multiline