Triple-strings

Brendan Eich brendan at mozilla.com
Wed Aug 24 09:19:45 PDT 2011


On Aug 24, 2011, at 2:44 AM, Dmitry A. Soshnikov wrote:

> Hi again,
> 
> And another topic which I'd like to separate from the doc-comments topic is the "triple-strings". The rationale is not to escape the double/single quotes when describing something bigger than one line (usually these are comments, but other simple strings with many of double quotes are also the case).

We had a triple-quoted string proposal for ES4. That was long ago.

http://wiki.ecmascript.org/doku.php?id=proposals:triple_quotes

The answer now is quasi-literals:

http://wiki.ecmascript.org/doku.php?id=harmony:quasis

No need to stutter " three times -- just use `. Did you miss this one? I need to talk it up more.

/be


More information about the es-discuss mailing list