The [String.raw spec](https://tc39.es/ecma262/#sec-string.raw) uses just the `raw` property of its first argument, which is a useful way of using it in user-defined tag functions to do the work of interleaving strings and values as well as converting the values to strings. Fixes #43609.
8 lines
507 B
Plaintext
8 lines
507 B
Plaintext
=== tests/cases/compiler/stringRawType.ts ===
|
|
String.raw({ raw: ["foo", "bar", "baz"] }, 1, 2);
|
|
>String.raw : Symbol(StringConstructor.raw, Decl(lib.es2015.core.d.ts, --, --))
|
|
>String : Symbol(String, Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --), Decl(lib.es2015.core.d.ts, --, --), Decl(lib.es2015.iterable.d.ts, --, --) ... and 1 more)
|
|
>raw : Symbol(StringConstructor.raw, Decl(lib.es2015.core.d.ts, --, --))
|
|
>raw : Symbol(raw, Decl(stringRawType.ts, 0, 12))
|
|
|