# gt: General Translation CLI tool: GT URL: https://generaltranslation.com/en-GB/docs/cli/reference/formats/gt-jsx-files.mdx --- title: GT description: Translate gt-next, gt-react, and gt-react-native projects with General Translation. API reference for the gt file format. --- The `gt` file format contains the translations for projects that use [`gt-react`, `gt-next`, or `gt-react-native`](/docs/react/overview). When you run [`gt translate`](/docs/cli/reference/commands/translate), the CLI scans your source code for inline content — such as [``](/docs/react/reference/components/t) components and [`useGT`](/docs/react/reference/hooks/use-gt) calls — along with your dictionary, and writes the results in this format. ## Configuration [#config] Add a `gt` entry under `files`. It accepts an `output` path with a `[locale]` placeholder for saving translations locally. ```json title="gt.config.json" { "defaultLocale": "en", "locales": ["fr", "es"], "files": { "gt": { "output": "public/i18n/[locale].json" } } } ``` This saves French and Spanish translations to `public/i18n/fr.json` and `public/i18n/es.json`, which you can load with [`loadTranslations`](/docs/react/reference/functions/load-translations). ## Storage options [#storage] * **Local:** set `output` to bundle translations in your app. This is the default — the CLI does not publish to the CDN with this configuration. * **CDN:** omit `output` and enable publishing to load translations at runtime instead. See [CDN publishing](/docs/cli/reference/config#cdn-publishing). Currently, only one output file per locale can be generated. ## Inline content parsing [#parsing] The `gt` entry accepts a `parsingFlags` object that controls how the CLI parses inline content. All flags are disabled by default. ```json title="gt.config.json" { "files": { "gt": { "parsingFlags": { "autoderive": true, "enableAutoJsxInjection": true, "includeSourceCodeContext": true, "legacyGtReactImportSource": false } } } } ``` * `autoderive` — parses interpolated values in `t()`, `gt()`, and `msg()` calls and expressions inside `` components as if wrapped in `derive()`, generating a separate translation entry for each possible value. Accepts `true` or an object such as `{ "jsx": true, "strings": false }`. See [Auto-derive translations](/docs/cli/guides/using-autoderive). * `enableAutoJsxInjection` — wraps translatable JSX text in `` components at build time, so you do not have to add them manually. See [Automatic JSX injection](/docs/cli/guides/using-auto-jsx). * `includeSourceCodeContext` — includes the surrounding source code lines as additional context for each translation. Replaces the deprecated top-level `files.gt.includeSourceCodeContext` key. * `legacyGtReactImportSource` — makes compiler-injected `gt-react` imports resolve to `gt-react/browser` for projects that need the legacy import path.