interface TemplateElement {
    leadingComments?: Comment[];
    loc?: null | SourceLocation;
    range?: [number, number];
    tail: boolean;
    trailingComments?: Comment[];
    type: "TemplateElement";
    value: { cooked?: null | string; raw: string };
}

Hierarchy (View Summary)

Properties

leadingComments?: Comment[]
loc?: null | SourceLocation
range?: [number, number]
tail: boolean
trailingComments?: Comment[]
type: "TemplateElement"
value: { cooked?: null | string; raw: string }

Type declaration

  • Optionalcooked?: null | string

    It is null when the template literal is tagged and the text has an invalid escape (e.g. - tag\unicode and \u{55})

  • raw: string