Closed lgf196 closed 4 years ago
Something like:
interface props {
title:string;
type:'small' |'middle' |'default'
}
type allTypes = props["type"];
It looks like this is a question rather than a bug report. This issue tracker is for tracking bugs and active work on TypeScript itself, rather than a general forum for programmers using TypeScript to get help or ask questions.
You can ask questions on sites like Stack Overflow. We are not able to provide one-on-one support on the issue tracker. Please read the issue template carefully - it has important information on what kinds of reports can be acted on here, as well as links to useful TypeScript resources. Thanks!
This issue has been marked as 'Question' and has seen no recent activity. It has been automatically closed for house-keeping purposes. If you're still waiting on a response, questions are usually better suited to stackoverflow.
Like interface props { title:string; type:'small' |'middle' |'default' } How can I get the value of type in the props interface?