We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
You can continue the conversation there. Go to discussion →
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We鈥檒l occasionally send you account related emails.
Already on GitHub? Sign in to your account
Type branding is made possible by intersecting a type with a object type that has a non-existent property hidden behind a symbol type.
import {A} from 'ts-toolbelt' type EUR = A.Type<number, 'eur'> type USD = A.Type<number, 'usd'> let eurWallet = 10 as EUR let usdWallet = 15 as USD eurWallet = usdWallet // error
nominal typing, branded types, opaque types, unique types
The text was updated successfully, but these errors were encountered:
No branches or pull requests
馃 Question
Describe your question
Type branding is made possible by intersecting a type with a object type that has a non-existent property hidden behind a symbol type.
Search tags, topics
nominal typing, branded types, opaque types, unique types
The text was updated successfully, but these errors were encountered: