---
title: "EnumU32: interface in Values, TypeShade API reference"
description: "EnumU32, an interface in Values. A typed u32 enum: a name-to-value map whose members are Node<'u32'> literals, plus the raw value map."
url: https://typeshade.dev/api/enumu32-interface/
language: en
---

# `EnumU32`

Interface in Values

A typed `u32` enum: a name-to-value map whose members are Node<'`u32`'> literals, plus the raw value map.

`import type { EnumU32 } from 'typeshade'`
`import type { EnumU32 } from 'typeshade/core/ir'`

The signature, the description and the examples come from the compiler's own source at commit af54ddad5.

## Syntax

```ts
interface EnumU32<M extends Record<string, number>> {
  readonly members: { readonly [K in keyof M]: Node<'u32'> };
  readonly values: M;
}
```

## Description

Pair it with [`matchEnum`](https://typeshade.dev/api/matchenum/) for exhaustive integer dispatch: the arms object must cover every member, and a missing or unknown key is a `tsc` error, so a forgotten case is caught at compile time instead of falling through the `switch` default.

## Instance properties

**`members` read only `{ readonly [K in keyof M]: Node<'u32'> }`**

Typed member literals: `Kind.members.Fill` is a `Node<'u32'>` holding that member’s value.

**`values` read only `M`**

The raw name-to-value map, the integer case labels [`matchEnum`](https://typeshade.dev/api/matchenum/) dispatches on.

## See also

- [`matchEnum`](https://typeshade.dev/api/matchenum/)

## Source

[`src/core/ir/node.ts`, line 2067](https://github.com/typeshade/typeshade/blob/af54ddad5/src/core/ir/node.ts#L2067), at commit af54ddad5
