github.com/tilt-dev/tilt@v0.33.15-0.20240515162809-0a22ed45d8a0/web/src/annotations.tsx (about) 1 // get annotations from an api object w/ a reasonable type 2 // 3 // (our codegen generates the `annotations` field with type `object`, which is not very useful) 4 export function annotations(obj: { metadata?: Proto.v1ObjectMeta }): { 5 [name: string]: string 6 } { 7 return (obj.metadata?.annotations ?? {}) as { [name: string]: string } 8 }