type obj = { a: 1, b: "one", c: true }
function updateObj(key: keyof obj, value: obj[typeof key] ) {
}
Currently the parameter; value in the updateObj function is a union of all the values of the type obj. However, i want it to reference only the value of the key that was passed to the function.