-
Notifications
You must be signed in to change notification settings - Fork 13k
Closed
Labels
Awaiting More FeedbackThis means we'd like to hear from more people who would be helped by this featureThis means we'd like to hear from more people who would be helped by this featureSuggestionAn idea for TypeScriptAn idea for TypeScript
Description
TypeScript Version: 2.1.5
Expected behavior:
const foo = 'world'; // value type: 'world'
const bar = `hello ${foo}`; // value type: 'hello world'
Actual behavior:
const foo = 'world'; // value type: 'world'
const bar = `hello ${foo}`; // type: 'string'
Motivation
For constants which are created from other constants the IntelliSense is often more useful, when we see its value type instead of the "real" type.
More practical example:
const fooBreakpoint = '800px';
const fooMediaQuery = `@media(min-width: ${fooBreakpoint})`;
When fooMediaQuery
is used I'd like to see @media(min-width: 800px)
as its type instead of string
.
rob3c, axefrog, fjmorel, ethanresnick, cpplearner and 13 more
Metadata
Metadata
Assignees
Labels
Awaiting More FeedbackThis means we'd like to hear from more people who would be helped by this featureThis means we'd like to hear from more people who would be helped by this featureSuggestionAn idea for TypeScriptAn idea for TypeScript