---
id: "packages/active-grid/api/grid-translation-context"
title: "Grid translation context"
description: "useGridTranslation, useGridLocale, GridTranslateFunction: generated from the source of active-grid."
url: "/packages/active-grid/api/grid-translation-context"
locale: "en"
revision: "g0mvk5qxml-7b52bf0b:grid-translation-context"
---

# Grid translation context

Exported by `@workspace/active-grid`. Generated from the package source; part of [the index of every export](/packages/active-grid/api).

## Functions, hooks and constants

**useGridTranslation**: `() => GridTranslateFunction`

The effective translator of the enclosing grid, including an instance
override: for a custom cell or editor that renders grid-owned words.

**useGridLocale**: `() => GridPresentation`

The effective presentation of the enclosing grid, including an instance
override: a locale code or a presentation context. Pass it straight to the
central active-format formatters; never read fields off it here.

There is no default (active-format D14): outside a grid this throws.

## Types

**GridTranslateFunction**

```ts
type GridTranslateFunction = (
  key: string,
  variables?: Record<string, string | number | undefined>,
) => string;
```

Translation function type — compatible with active-i18n's TranslateFunction.
The package does NOT read active-i18n's React context (no provider
dependency); the consumer passes `t` explicitly.
