3

TypeScript Fundamentals × Satisfies and as const

 1 year ago
source link: https://syntax.fm/show/560/typescript-fundamentals-satisfies-and-as-const
Go to the source link to view the article. You can view the picture content, updated content and better typesetting reading experience. If the link is broken, please click the button below to view the snapshot at that time.
neoserver,ios ssh client

Jan 9th, 2023

TypeScript Fundamentals × Satisfies and as const

👇 Download Show✏️ Edit Show Notes

In this Hasty Treat, Scott and Wes talk about Satisfies and as const.

Show Notes

export const currencies = {
USD: 'US Dollars',
CAD: 'Canadian Dollar',
EUR: 'Euro',
} as const;

export type Currency = typeof currencies;
export type CurrencyCode = keyof Currency;

Tweet us your tasty treats


About Joyk


Aggregate valuable and interesting links.
Joyk means Joy of geeK