# NumericValue

Format a number with tabular figures and optional space for its expected width.

Connect Flood once using [the installation guide](https://flood.md/docs/installation). Then import the components you use; no per-component add command is needed.

## Example

```tsx
"use client";

import { FloodRoot, NumericValue } from "@flood-md/react";
import "@flood-md/react/styles.css";

export function Example() {
  return (
    <FloodRoot>
      <NumericValue value={999} reserveFor={-9999} lang="en" />
    </FloodRoot>
  );
}
```

## Design notes

- Use in measurements, counters and numerical columns. Supply a finite number or a bigint for an exact large integer. Native NumberFormat options control separators, rounding, units and currency. The data element preserves the underlying value.
- Use reserveFor only where changing width moves neighboring content. Choose a representative widest value in the same notation, including signs, grouping, fractions or currency where they may appear.
- The value can grow beyond the reserve. Align end for comparable values or start when the figure is read from a shared leading edge. When values could outgrow the available width, define the wrapping or overflow behavior in the enclosing composition.
- Use Duration when elapsed time needs a fixed unit and MoneyField when the user edits an exact monetary amount.

## API reference

| Prop | Values | Default |
| --- | --- | --- |
| `value` | `number \| bigint` | `Required` |
| `formatOptions` | `Intl.NumberFormatOptions` | `—` |
| `reserveFor` | `number \| bigint` | `—` |
| `align` | `"start" \| "end"` | `"end"` |
| `Native HTML props` | `Omit<HTMLAttributes<HTMLDataElement>, "children">` | `Forwarded` |
