Created
December 17, 2019 18:24
-
-
Save carlrip/a85a1af7f92e7d0186b7379c9a8a8795 to your computer and use it in GitHub Desktop.
const assertions - literals
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const Status = { | |
Loading: "LOADING", | |
Loaded: "LOADED", | |
} as const ; | |
logStatus(Status.Loading); // Type is "LOADING" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment