Created
March 23, 2021 19:41
-
-
Save eamonnboyle/bcc3b9aebf22a4bc92e4685af30daacd to your computer and use it in GitHub Desktop.
Leading and Middle Variadic Tuples
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
type Student = [string, ...number[], boolean]; | |
const bob: Student = ['Bob', true]; | |
const sally: Student = ['Sally', 100, true]; | |
const jane: Student = ['Jane', 80, 90, 100, true]; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment