# Types and generics

> Props types can live in their own files, a child's module or a package, components can be generic, and exported types reach consumers in every framework.

Types let a component tell the people who use it what it accepts, and let their editor catch a mistake before anyone runs the page. A design system keeps them apart from the components: a `ButtonProps` in a shared file, a `Tone` that several components read, a list typed by the items it's given. Think of a props interface copied into every component that needs it until two copies disagree, a list whose `selected` item can be anything at all, or a consumer who passes `tone="danger"` to a button that has no such tone and only finds out in the browser.

This page walks you through the types Unframework reads and what each framework's output does with them. We'll look at:

- **Props types from other files:** a `.ts` module, a child's module or a package.
- **What the compiler reads:** `extends`, intersections, the five utility types, and what stays out.
- **Generic components:** `function List<T>`, in each framework's own generic form.
- **Exported types:** what a consumer imports, and how it's checked.

## Props types from other files

A component's props type can come from a relative `.ts` module, as a design system declares them:

<!-- prettier-ignore -->
```ts [types.ts]
// The props of `Badge`, declared in a module of their own, as a design system declares them.
export interface BadgeProps {
  /** The text the badge shows. */
  label: string;
  tone?: "info" | "danger";
}
```

<!-- prettier-ignore -->
```tsx [Badge.uf.tsx]
import type { BadgeProps } from "./types";

export default function Badge({ label, tone = "info" }: BadgeProps) {
  return <span class={`badge badge-${tone}`}>{label}</span>;
}
```

The compiler reads the members through its type oracle, so it knows that `label` is a required string and `tone` an optional literal union with a default. Each output imports `BadgeProps` by name, rather than printing its members again, so your editor shows the type you wrote, with its comments:

::framework-switcher

#react

<!-- prettier-ignore -->
```tsx [Badge.tsx]
import { cx } from "./_unframework/cx";
import type { BadgeProps } from "./types";
import type { ComponentPropsWithRef } from "react";

export type BadgeAttributes = Omit<ComponentPropsWithRef<"span">, "label" | "tone" | "children">;

export default function Badge({
  label,
  tone = "info",
  className,
  style,
  ...attributes
}: BadgeProps & BadgeAttributes) {
  return (
    <span className={cx(`badge badge-${tone}`, className)} style={style} {...attributes}>
      {label}
    </span>
  );
}
```

#vue

<!-- prettier-ignore -->
```vue [Badge.vue]
<script setup lang="ts">
import type { BadgeProps } from "./types";

const { label, tone = "info" } = defineProps<BadgeProps>();
</script>

<template>
  <span :class="`badge badge-${tone}`">{{ label }}</span>
</template>
```

#svelte

<!-- prettier-ignore -->
```svelte [Badge.svelte]
<svelte:options runes={true} preserveWhitespace={false} />

<script lang="ts">
  import type { BadgeProps } from "./types";
  import type { ClassValue, SvelteHTMLElements } from "svelte/elements";

  type Props = Omit<
    SvelteHTMLElements["span"],
    "label" | "tone" | "children" | "class" | "style" | "ref"
  > &
    BadgeProps & { class?: ClassValue; style?: string; ref?: HTMLElementTagNameMap["span"] | null };

  let {
    label,
    tone = "info",
    class: className,
    style,
    ref = $bindable(null),
    ...attributes
  }: Props = $props();
</script>

<span
  class={[`badge badge-${tone}`, className]}
  {style}
  bind:this={ref}
  {...attributes}
>{label}</span>
```

#angular

<!-- prettier-ignore -->
```ts [badge.ts]
import { Fallthrough } from "./_unframework/Fallthrough";
import type { Listeners } from "./_unframework/Listeners";
import { ScopeAttributes } from "./_unframework/ScopeAttributes";
import type { BadgeProps } from "./types";
import { Component, ElementRef, inject, input, viewChild } from "@angular/core";

@Component({
  selector: "uf-badge",
  imports: [ScopeAttributes, Fallthrough],
  host: { "[attr.class]": "null", "[attr.style]": "'display: contents;'" },
  preserveWhitespaces: false,
  template: `
    @let label = this.label();
    @let tone = this.tone();
    <span
      [class]="['badge badge-' + tone, this.class()].join(' ')"
      [style]="this.style()"
      [ufFallthrough]="{ attributes: this.ufAttributes(), listeners: this.ufListeners() }"
      [ufScope]="this.host"
      #ufElement
    >{{ label }}</span>
  `,
})
export default class Badge {
  readonly label = input.required<BadgeProps["label"]>();
  readonly tone = input<Exclude<BadgeProps["tone"], undefined>, BadgeProps["tone"]>("info", {
    transform: (value) => (value === undefined ? "info" : value),
  });
  readonly class = input<string>();
  readonly style = input<Record<string, string | null | undefined>>();
  readonly ufAttributes = input<Record<string, unknown>>();
  readonly ufListeners = input<Listeners>();
  readonly ufElement = viewChild<ElementRef<HTMLSpanElement>>("ufElement");
  protected readonly host = inject<ElementRef<HTMLElement>>(ElementRef).nativeElement;
}
```

#solid

<!-- prettier-ignore -->
```tsx [Badge.tsx]
import { cx } from "./_unframework/cx";
import type { BadgeProps } from "./types";
import { type ComponentProps, type JSX, mergeProps, splitProps } from "solid-js";

export default function Badge(
  rawProps: BadgeProps &
    Omit<ComponentProps<"span">, "label" | "tone" | "style"> & { style?: JSX.CSSProperties },
) {
  const props = mergeProps({ tone: "info" } satisfies Partial<BadgeProps>, rawProps);
  const [, others] = splitProps(props, ["label", "tone", "class"]);

  return (
    <span class={cx(`badge badge-${props.tone}`, props.class)} {...others}>
      {props.label}
    </span>
  );
}
```

#qwik

<!-- prettier-ignore -->
```tsx [Badge.tsx]
import type { BadgeProps } from "./types";
import { type CSSProperties, type ClassList, type PropsOf, component$ } from "@qwik.dev/core";

export default component$<
  BadgeProps &
    Omit<PropsOf<"span">, "label" | "tone" | "class" | "style"> & {
      class?: ClassList;
      style?: CSSProperties;
    }
>(({ label, tone = "info", class: className, style, ...attributes }) => {
  return (
    <span class={[`badge badge-${tone}`, className]} style={style} {...attributes}>
      {label}
    </span>
  );
});
```

#astro

<!-- prettier-ignore -->
```astro [Badge.astro]
---
import type { BadgeProps } from "./types";
import type { HTMLAttributes } from "astro/types";

interface Props extends BadgeProps, Omit<HTMLAttributes<"span">, "label" | "tone"> {
  class?: string;
  style?: Record<string, string | number | undefined>;
}

const { label, tone = "info", class: className, style, ...attrs } = Astro.props;
---

<span class:list={[`badge badge-${tone}`, className]} style={style} {...attrs}>{label}</span>
```

::

Each output tree also holds `types.ts`, copied unchanged, so every output checks and loads on its own. Angular declares each input on its own, typed through the interface: `BadgeProps["label"]`.

A type can come from a child's module too. Here a form's prop is typed with the props its child exports:

<!-- prettier-ignore -->
```tsx [Form.uf.tsx]
import Field from "./Field.uf.tsx";
import type { FieldProps } from "./Field.uf.tsx";

// A props type a child's module exports, imported from the child (ADR-0067).
export default function Form({ field }: { field: FieldProps }) {
  return (
    <form aria-label="Sign up">
      <Field name={field.name} label={field.label} />
    </form>
  );
}
```

And from a package, through its `types` and `exports`, as TypeScript's bundler resolution finds them. `value` and `interval` come from rxjs's generic `TimeInterval<T>`, and `label` from a local module:

<!-- prettier-ignore -->
```tsx [Status.uf.tsx]
import type { TimeInterval } from "rxjs";

import type { Labelled } from "./types";

// Members a package declares, `value` and `interval` from rxjs's generic `TimeInterval<T>`, beside
// one a `.ts` module declares.
type StatusProps = TimeInterval<string> & Labelled;

export default function Status({ value, interval, label }: StatusProps) {
  return (
    <p>
      {label}: {value} after {interval} ms
    </p>
  );
}
```

## What the compiler reads

The compiler reads a props type as written, without running a type checker, so the same source always gives the same props. It follows:

- interfaces and type aliases, local or imported, and their re-exports;
- `extends` chains, across modules (`types/extends-chain`);
- intersections of interfaces and type literals (`types/intersection-props`);
- unions and literal unions;
- generic declarations, instantiated with their arguments;
- the five utility types: `Partial`, `Required`, `Pick`, `Omit` and `Readonly`.

For example, the props of a text field can pick what they require from a looser interface:

<!-- prettier-ignore -->
```ts [types.ts]
// Every option of a field is optional: the component's props pick the ones it requires.
export interface FieldOptions {
  name?: string;
  label?: string;
  placeholder?: string;
  required?: boolean;
}
```

<!-- prettier-ignore -->
```tsx [TextField.uf.tsx]
import type { FieldOptions } from "./types";

// The five utility types of plan §5.5, over an imported interface.
export type TextFieldProps = Required<Pick<FieldOptions, "name" | "label">> &
  Readonly<Partial<Omit<FieldOptions, "name" | "label">>>;

export default function TextField({ name, label, placeholder, required }: TextFieldProps) {
  return (
    <label>
      {label}
      <input name={name} placeholder={placeholder} required={required} />
    </label>
  );
}
```

`name` and `label` are required, and `placeholder` and `required` optional and read-only. Vue's compiler resolves that alias by itself, so Vue's output keeps it as written:

<!-- prettier-ignore -->
```vue [TextField.vue]
<script setup lang="ts">
import type { FieldOptions } from "./types";

export type TextFieldProps = Required<Pick<FieldOptions, "name" | "label">> &
  Readonly<Partial<Omit<FieldOptions, "name" | "label">>>;

const {
  name,
  label,
  placeholder = undefined,
  required = undefined,
} = defineProps<TextFieldProps>();
</script>

<template>
  <label>{{ label }}<input :name="name" :placeholder="placeholder" :required="required" /></label>
</template>
```

Where Vue's compiler can't resolve a construct, such as a type from a package, Vue's output prints one member for each prop, each typed through the original:

<!-- prettier-ignore -->
```vue [Status.vue]
<script setup lang="ts">
import type { Labelled } from "./types";
import type { TimeInterval } from "rxjs";

type StatusProps = TimeInterval<string> & Labelled;

const { value, interval, label } = defineProps<{
  value: StatusProps["value"];
  interval: StatusProps["interval"];
  label: StatusProps["label"];
}>();
</script>

<template>
  <p>{{ label }}: {{ value }} after {{ interval }} ms</p>
</template>
```

Every other output keeps `StatusProps` and imports what it names.

### What stays out

A props type the compiler can't read for every framework is a diagnostic at its span, never a guess:

- [UF6001](/docs/reference/diagnostics#UF6001): the type names a declaration the compiler can't find, such as a typo, a missing file or a package without types.
- [UF6002](/docs/reference/diagnostics#UF6002): conditional and mapped types, `infer`, `keyof`, `typeof` and template-literal types, which need a type checker.
- [UF6003](/docs/reference/diagnostics#UF6003): the type is declared in another module without `export`, so no output can import it.
- [UF6004](/docs/reference/diagnostics#UF6004): the props type isn't an object type, such as a union of two object types.
- [UF6005](/docs/reference/diagnostics#UF6005): an intersection or an `extends` chain declares one prop twice, with two types.

For UF6002, `compile()` takes a second type oracle, `createTsgoOracle({ root })` from `@unframework.dev/type-oracle-tsgo`, which hands those constructs to TypeScript's own checker. The Vite plugin always uses the default one.

## Generic components

A list, a select or a table is often generic over its items. Declare the type parameter on the component's function, and let its props take it:

<!-- prettier-ignore -->
```tsx [List.uf.tsx]
// A component generic over its items (ADR-0068): `T` is what its consumer's `items` holds.
export interface ListProps<T> {
  label: string;
  items: T[];
  selected?: T;
}

export default function List<T>({ label, items, selected }: ListProps<T>) {
  return (
    <ul aria-label={label}>
      {items.map((item, index) => (
        <li key={index} aria-current={item === selected ? "true" : undefined}>
          {String(item)}
        </li>
      ))}
    </ul>
  );
}
```

A consumer never names `T`: it comes from the `items` they pass, so `selected` must be one of them. Each framework writes it in its own generic form:

::framework-switcher

#react

<!-- prettier-ignore -->
```tsx [List.tsx]
import type { ComponentPropsWithRef } from "react";

export interface ListProps<T> {
  label: string;
  items: T[];
  selected?: T;
}

export type ListAttributes = Omit<
  ComponentPropsWithRef<"ul">,
  "label" | "items" | "selected" | "children"
>;

export default function List<T>({
  label,
  items,
  selected,
  className,
  style,
  ...attributes
}: ListProps<T> & ListAttributes) {
  return (
    <ul aria-label={label} className={className} style={style} {...attributes}>
      {items.map((item, index) => (
        <li key={index} aria-current={item === selected ? "true" : undefined}>
          {String(item)}
        </li>
      ))}
    </ul>
  );
}
```

#vue

<!-- prettier-ignore -->
```vue [List.vue]
<script setup lang="ts" generic="T">
export interface ListProps<T> {
  label: string;
  items: T[];
  selected?: T;
}

const { label, items, selected = undefined } = defineProps<ListProps<T>>();
</script>

<template>
  <ul :aria-label="label">
    <li
      v-for="(item, index) in items"
      :key="index"
      :aria-current="item === selected ? 'true' : undefined"
    >{{ String(item) }}</li>
  </ul>
</template>
```

#svelte

<!-- prettier-ignore -->
```svelte [List.svelte]
<svelte:options runes={true} preserveWhitespace={false} />

<script lang="ts" module>
  export interface ListProps<T> {
    label: string;
    items: T[];
    selected?: T;
  }
</script>

<script lang="ts" generics="T">
  import type { ClassValue, SvelteHTMLElements } from "svelte/elements";

  type Props = Omit<
    SvelteHTMLElements["ul"],
    "label" | "items" | "selected" | "children" | "class" | "style" | "ref"
  > &
    ListProps<T> & { class?: ClassValue; style?: string; ref?: HTMLElementTagNameMap["ul"] | null };

  let {
    label,
    items,
    selected,
    class: className,
    style,
    ref = $bindable(null),
    ...attributes
  }: Props = $props();
</script>

<ul aria-label={label} class={className} {style} bind:this={ref} {...attributes}>
  {#each items as item, index (index)}
    <li aria-current={item === selected ? "true" : undefined}>{String(item)}</li>
  {/each}
</ul>
```

#angular

<!-- prettier-ignore -->
```ts [list.ts]
import { Fallthrough } from "./_unframework/Fallthrough";
import type { Listeners } from "./_unframework/Listeners";
import { ScopeAttributes } from "./_unframework/ScopeAttributes";
import { Component, ElementRef, inject, input, viewChild } from "@angular/core";

export interface ListProps<T> {
  label: string;
  items: T[];
  selected?: T;
}

@Component({
  selector: "uf-list",
  imports: [ScopeAttributes, Fallthrough],
  host: { "[attr.class]": "null", "[attr.style]": "'display: contents;'" },
  preserveWhitespaces: false,
  template: `
    @let label = this.label();
    @let items = this.items();
    @let selected = this.selected();
    <ul
      [attr.aria-label]="'aria-label' in (this.ufAttributes() ?? {}) ? this.ufAttributes()?.['aria-label'] : label"
      [class]="this.class()"
      [style]="this.style()"
      [ufFallthrough]="{ attributes: this.ufAttributes(), listeners: this.ufListeners() }"
      [ufScope]="this.host"
      #ufElement
    >
      @for (item of items; track index; let index = $index) {
        <li [attr.aria-current]="item === selected ? 'true' : undefined">{{ String(item) }}</li>
      }
    </ul>
  `,
})
export default class List<T> {
  readonly label = input.required<string>();
  readonly items = input.required<T[]>();
  readonly selected = input<T>();
  readonly class = input<string>();
  readonly style = input<Record<string, string | null | undefined>>();
  readonly ufAttributes = input<Record<string, unknown>>();
  readonly ufListeners = input<Listeners>();
  readonly ufElement = viewChild<ElementRef<HTMLUListElement>>("ufElement");
  protected readonly String = String;
  protected readonly host = inject<ElementRef<HTMLElement>>(ElementRef).nativeElement;
}
```

#solid

<!-- prettier-ignore -->
```tsx [List.tsx]
import { KeyedFor } from "./_unframework/KeyedFor";
import { type ComponentProps, type JSX, splitProps } from "solid-js";

export interface ListProps<T> {
  label: string;
  items: T[];
  selected?: T;
}

export default function List<T>(
  props: ListProps<T> &
    Omit<ComponentProps<"ul">, "label" | "items" | "selected" | "style"> & {
      style?: JSX.CSSProperties;
    },
) {
  const [, others] = splitProps(props, ["label", "items", "selected"]);

  return (
    <ul aria-label={props.label} {...others}>
      <KeyedFor each={props.items} by={(item, index) => index}>
        {(item) => (
          <li aria-current={item.value === props.selected ? "true" : undefined}>
            {String(item.value)}
          </li>
        )}
      </KeyedFor>
    </ul>
  );
}
```

#qwik

<!-- prettier-ignore -->
```tsx [List.tsx]
import { type CSSProperties, type ClassList, type PropsOf, component$ } from "@qwik.dev/core";

export interface ListProps<T> {
  label: string;
  items: T[];
  selected?: T;
}

export default component$(
  <T,>({
    label,
    items,
    selected,
    class: className,
    style,
    ...attributes
  }: ListProps<T> &
    Omit<PropsOf<"ul">, "label" | "items" | "selected" | "class" | "style"> & {
      class?: ClassList;
      style?: CSSProperties;
    }) => {
    return (
      <ul aria-label={label} class={className} style={style} {...attributes}>
        {items.map((item, index) => (
          <li key={index} aria-current={item === selected ? "true" : undefined}>
            {String(item)}
          </li>
        ))}
      </ul>
    );
  },
);
```

#astro

<!-- prettier-ignore -->
```astro [List.astro]
---
import type { HTMLAttributes } from "astro/types";

export interface ListProps<T> {
  label: string;
  items: T[];
  selected?: T;
}

interface Props<T>
  extends ListProps<T>, Omit<HTMLAttributes<"ul">, "label" | "items" | "selected"> {
  class?: string;
  style?: Record<string, string | number | undefined>;
}

const {
  label,
  items,
  selected,
  class: className,
  style,
  "aria-label": ariaLabel,
  ...attrs
} = Astro.props;
---

<ul
  aria-label={"aria-label" in Astro.props ? ariaLabel : label}
  class:list={[className]}
  style={style}
  {...attrs}
>
  {items.map((item) => (
    <li aria-current={item === selected ? "true" : undefined}>{String(item)}</li>
  ))}
</ul>
```

::

| Target       | Generic form                                                      |
| ------------ | ----------------------------------------------------------------- |
| React, Solid | a generic function component                                      |
| Vue          | `<script setup lang="ts" generic="T">`                            |
| Svelte       | `<script lang="ts" generics="T">`                                 |
| Angular      | a generic component class, whose `T` Angular infers from inputs   |
| Qwik         | a generic arrow inside `component$`, `<T,>(…) => …`, with no cast |
| Astro        | `interface Props<T>`                                              |

A type parameter can take a constraint, `function Table<T extends { id: string; label: string }>` (`generics/constrained`). Explicit type arguments on a tag, `<List<string> … />`, are [UF6006](/docs/reference/diagnostics#UF6006), and so is a generic component as a candidate of `<component is>`, since several frameworks' templates have no form for them.

### Scoped slots on Angular

A scoped slot's props can name the type parameter too, so a consumer's fill reads their own item type:

<!-- prettier-ignore -->
```tsx [Picker.uf.tsx]
import { defineSlots } from "@uxfront/unframework";
import type { Element } from "@uxfront/unframework";

// A scoped slot whose props name the type parameter (ADR-0068): a consumer's fill reads `T`.
export interface PickerProps<T> {
  items: T[];
}

export default function Picker<T>({ items }: PickerProps<T>) {
  const slots = defineSlots<{ item?(props: { item: T }): Element }>();
  return (
    <ul>
      {items.map((item, index) => (
        <li key={index}>{slots.item?.({ item })}</li>
      ))}
    </ul>
  );
}
```

React, Vue, Svelte, Solid, Qwik and Astro type the fill's `item` by the type argument the consumer's `items` give. Angular infers a component's type parameter from its inputs alone, and a slot's directive can't infer it, so the slot's context takes the parameter's constraint, and an unconstrained `T` reads as `any`:

<!-- prettier-ignore -->
```ts [picker.ts]
export type PickerItemContext = { item: any };
```

The component renders the same. Only a consumer's type checking differs, so the compiler says so for information, with [UF4004](/docs/reference/diagnostics#UF4004) at the slot (`generic-slot-props` on the [targets page](/docs/reference/targets#capabilities)). Give `T` a constraint that names what consumers read, or accept the looser type on Angular.

## Exported types

Every type a component's module exports, each output exports under the same name: its props type, a type the props reach, and one that no component uses at all:

<!-- prettier-ignore -->
```tsx [Button.uf.tsx]
// Every type the module exports is exported by each output (ADR-0068): one the props reach, and
// one no component reaches.
export type ButtonTone = "primary" | "secondary";

export type ButtonSize = "small" | "large";

export interface ButtonProps {
  label: string;
  tone?: ButtonTone;
}

export default function Button({ label, tone = "primary" }: ButtonProps) {
  return (
    <button type="button" class={`button button-${tone}`}>
      {label}
    </button>
  );
}
```

React, Solid, Qwik and Angular export them from the module, Vue from `<script setup>`, Astro from its frontmatter, and Svelte from `<script module>`:

<!-- prettier-ignore -->
```svelte [Button.svelte]
<svelte:options runes={true} preserveWhitespace={false} />

<script lang="ts" module>
  export type ButtonTone = "primary" | "secondary";

  export type ButtonSize = "small" | "large";

  export interface ButtonProps {
    label: string;
    tone?: ButtonTone;
  }
</script>

<script lang="ts">
  import type { ClassValue, HTMLButtonAttributes } from "svelte/elements";

  type Props = Omit<
    HTMLButtonAttributes,
    "label" | "tone" | "children" | "class" | "style" | "ref"
  > &
    ButtonProps & {
      class?: ClassValue;
      style?: string;
      ref?: HTMLElementTagNameMap["button"] | null;
    };

  let {
    label,
    tone = "primary",
    class: className,
    style,
    ref = $bindable(null),
    ...attributes
  }: Props = $props();
</script>

<button
  type="button"
  class={[`button button-${tone}`, className]}
  {style}
  bind:this={ref}
  {...attributes}
>{label}</button>
```

So a consumer imports them as they would from any component written in their framework, and their checker reports a misuse. The tests type-check a consumer in each framework, like this React one, which must fail at the two lines its comments name:

<!-- prettier-ignore -->
```tsx [MisuseType.tsx]
import Button, {
  type ButtonProps,
  type ButtonSize,
} from "../../../../../integration/cases/types/exported-types/__output__/react/Button";

export function MisuseType() {
  // @uf-expect TS2322 Button.type:ButtonProps
  const props: ButtonProps = { label: "Save", tone: "danger" };
  // @uf-expect TS2322 Button.type:ButtonSize
  const size: ButtonSize = "huge";
  return <Button label={props.label} data-size={size} />;
}
```

A module can re-export a type it imports, so its consumers find it beside the component:

<!-- prettier-ignore -->
```tsx [Palette.uf.tsx]
import Swatch from "./Swatch.uf.tsx";
import type { Tone } from "./types";

// Consumers of `Palette` import the shared type from it.
export type { Tone } from "./types";

export default function Palette({ tone }: { tone: Tone }) {
  return (
    <div class="palette">
      <Swatch tone={tone} />
    </div>
  );
}
```

To read a component's full props, attributes included, use the framework's own utility:

| Target               | Its props                                           |
| -------------------- | --------------------------------------------------- |
| React, Solid, Svelte | `ComponentProps<typeof Button>`                     |
| Vue                  | `InstanceType<typeof Button>["$props"]`             |
| Qwik                 | `PropsOf<typeof Button>`                            |
| Astro                | `ComponentProps<typeof Button>`, from `astro/types` |

Angular has no such utility for a component's inputs, so an Angular consumer imports the exported props type, `ButtonProps`, instead.

The `…Events`, `…Models` and `…Slots` interfaces that an output exports beside its component, such as `FieldEvents` on [Child components](/docs/components/child-components), stay as they are.

The decisions behind this page are [ADR-0067](https://github.com/uxfront-com/unframework/blob/main/docs/adrs/0067-the-type-oracle-and-cross-file-props-types.md) and [ADR-0068](https://github.com/uxfront-com/unframework/blob/main/docs/adrs/0068-generic-components-and-exported-public-types.md). Values shared between components, rather than types, are on [Shared modules](/docs/components/shared-modules).
