# translator (/jsdoc/pixi-vn-json/index/namespaces/translator)



Manages the translation pipeline for all text displayed by pixi-vn-json.

The pipeline applies three optional hooks in order:

1. `beforeToTranslate` – pre-processes the key before translation.
2. `translate` – the main translation function (identity by default).
3. `afterToTranslate` – post-processes the translated string.

Use [TranslatorManager.t](/jsdoc/pixi-vn-json/index/namespaces/translator/functions/t) to translate a key or array of keys.

## Variables [#variables]

* [~~afterToTranslate~~](/jsdoc/pixi-vn-json/index/namespaces/translator/variables/afterToTranslate)
* [~~beforeToTranslate~~](/jsdoc/pixi-vn-json/index/namespaces/translator/variables/beforeToTranslate)

## Functions [#functions]

* [generateJsonTranslation](/jsdoc/pixi-vn-json/index/namespaces/translator/functions/generateJsonTranslation)
* [setTranslate](/jsdoc/pixi-vn-json/index/namespaces/translator/functions/setTranslate)
* [t](/jsdoc/pixi-vn-json/index/namespaces/translator/functions/t)
* [translate](/jsdoc/pixi-vn-json/index/namespaces/translator/functions/translate)
