arktypea
arktype16mo ago
dibbo

Indexed Access Types

Hello, is it possible to recreate the SizeValues type below in arktype?
const sizes = [
  { label: "Big", value: "100kg" },
  { label: "Medium", value: "50kg" },
  { label: "Small", value: "10kg" },
] as const;

type SizeValues = typeof sizes[number]['value'][]
Was this page helpful?