i’m excited about the upcoming PRs, even tho some have been there for a while already.
https://github.com/microsoft/TypeScript/pull/26349
https://github.com/microsoft/TypeScript/issues/26242
and fwiw, i tried playing w/ it [1] before looking for `typescript infer object value by key` & finding [2] - might be interesting. there’s typeof & keyof that are often used for similar stuff that is possible.
[1] https://www.typescriptlang.org/play?#code/FAYw9gdgzgLgBAJwKYHM4F44G87DnAQwC44AKABxNgQEsIUBK[…]Ko9Oc4N73DAguijF9bI-fov2GZ8JmmADUwOPMTkzMCcyA-Mrlgu4gA
[2] https://stackoverflow.com/questions/54598322/how-to-make-typescript-infer-the-keys-of-an-object-but-define-type-of-its-value#[[(hidden) GPVT2QZsF]]961[…]0_54598743