Preview:```ts
const myNum = 123
const myString = "abc"
const myVars = {
nums: [myNum],
strs: [myString],
}
type MyVarsKey = keyof typeof myVars
const func = <K extends keyof typeof myVars>(
key: K,
index: number
) => {
return myVars[key][index]
}
const theNumber = func("nums", 0)
...```
You can choose specific lines to embed by selecting them before copying the link.