-
Notifications
You must be signed in to change notification settings - Fork 13.1k
Closed
Closed
Copy link
Labels
Out of ScopeThis idea sits outside of the TypeScript language design constraintsThis idea sits outside of the TypeScript language design constraintsRevisitAn issue worth coming back toAn issue worth coming back toSuggestionAn idea for TypeScriptAn idea for TypeScript
Description
TypeScript Version: 3.2
Search Terms: NoSubstitutionTemplateLiteral, import template literal
Code
import * as ts from `typescript`Expected behavior:
No error, as the NoSubstitutionTemplateLiteral should be treated just as a StringLiteral. Or potentially cannot find module error, depending on whether the module is installed.
Actual behavior:
Throws the error: "String literal expected"
Playground Link:
playground link
Related Issues:
This idea was touched on by #17704, but I guess this use case slipped through the cracks.
Tyler-Murphy
Metadata
Metadata
Assignees
Labels
Out of ScopeThis idea sits outside of the TypeScript language design constraintsThis idea sits outside of the TypeScript language design constraintsRevisitAn issue worth coming back toAn issue worth coming back toSuggestionAn idea for TypeScriptAn idea for TypeScript