# prodap-lore-locale

> Package used to carry out the internationalization of Lore

Latest version **0.33.11** (published 2026-10-05) · MIT license · 0 weekly downloads

## Install

```sh
npm install prodap-lore-locale
pnpm add prodap-lore-locale
yarn add prodap-lore-locale
bun add prodap-lore-locale
```

## Health

**Score 65/100 (B)** — status: active.

Positive: has types; no vulnerabilities; recently updated; high maintenance score; high quality score.

Warnings: low downloads; no esm support; pre 1.0.

## Facts

| | |
|---|---|
| Version | 0.33.11 |
| Published | 2026-10-05 |
| First published | 2022-10-10 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | bundled |
| Module format | CommonJS |
| Dependencies | 0 |
| Unpacked size | 2.4 MB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| Author | Antônio Marcos de Oliveira Souza |
| Maintainers | amarcosos, andretertuliano, amanda.souza, ana.gouvea, clayton.rios |
| Keywords | Prodap, DSM, DSM-Firmenich, Lore, TypeScript, Locale, Internationalization |

## Links

- npm: https://www.npmjs.com/package/prodap-lore-locale
- Repository: https://gitlab.com/prodap-tech/assistente-virtual/npm/prodap-lore-locale
- Homepage: https://apecuariadeprecisao.com.br/lore-inteligencia-artificial/
- Issues: https://apecuariadeprecisao.com.br/lore-inteligencia-artificial/
- npm.io page: https://npm.io/package/prodap-lore-locale

## Recent versions

- 0.33.11 (latest) — 2026-10-05
- 0.33.10 — 2026-10-02
- 0.33.9 — 2026-10-01
- 0.33.8 — 2026-10-01
- 0.33.7 — 2026-10-01
- 0.33.6 — 2026-10-01
- 0.33.5 — 2026-09-29
- 0.33.4 — 2026-09-29
- 0.33.3 — 2026-09-22
- 0.33.2 — 2026-09-02
- 0.33.1 — 2026-08-11
- 0.33.0 — 2026-07-31
- 0.32.12 — 2026-07-29
- 0.32.11 — 2026-07-24
- 0.32.10 — 2026-07-23
- … 662 more at https://npm.io/package/prodap-lore-locale/versions

## README

# Prodap Lore Locale

Package used to perform the internationalization of Lore.

See below how to search for specific localization and translation according to the key:

# Installation

This is a [Node.js](https://nodejs.org/download/release/latest/) library available through the [npm](https://www.npmjs.com/) registry.
Before installing, download and install [Node.js](https://nodejs.org/download/release/latest/). Node.js 18.10.0 or higher is required.

If this is a brand new project, make sure you create a `package.json` first with the command [`npm init`](https://docs.npmjs.com/creating-a-package-json-file).

Installation is done using the command [`yarn add`](https://classic.yarnpkg.com/lang/en/docs/cli/add/) or [`npm install`](https://docs.npmjs.com/getting-started/installing-npm-packages-locally):

```bash
$ yarn add prodap-lore-locale
```

or

```bash
$ npm install prodap-lore-locale
```

# Usage

Below are some ways to get the locale information contained in this library:

## Without the locale

Without passing the locale the class will return all locales.

```js
import { Locales } from 'prodap-lore-locale'

const locales = new Locales()

console.log(getLocales) // { "en-US": { "hello": "Hello", ... }, "pt-BR": { "hello": "Olá", ... } }
```

## Passing the locale

Passing the locale the class will return the corresponding locale.

```js
import { Locales } from 'prodap-lore-locale'

const locales = new Locales({ locale: 'pt-BR' })

console.log(getLocales) // { "pt-BR": { "hello": "Olá", ... } }
```

## Looking for a specific translation

When searching for a specific translation, simply enter the corresponding key.

```js
import { Locales } from 'prodap-lore-locale'

const locales = new Locales({ locale: 'pt-BR' })
const hello = locales.translate('hello') // { "hello": "Olá" }

console.log(hello) // Olá
```

## Looking for a specific translation and replace

When looking for a specific translation and want to replace some value, just type the corresponding key and use replace.

```js
import { Locales } from 'prodap-lore-locale'

const locales = new Locales({ locale: 'pt-BR' })
const helloPeople = locales.translate('hello_people').replace('{{VALUE}}', 'Lore') // { "hello_people": "Olá {{VALUE}}" }

console.log(helloPeople) // Olá Lore
```

## Get current library location

In this way it is possible to obtain the current library location.

```js
import { Locales } from 'prodap-lore-locale'

const locales = new Locales({ locale: 'pt-BR' })
const getCurrentLocale = locales.getCurrentLocale()

console.log(getCurrentLocale) // pt-BR
```

## Get library locations

In this way it is possible to obtain the library locations.

```js
import { Locales } from 'prodap-lore-locale'

const locales = new Locales()
const getLocales = locales.getLocales()

console.log(getLocales) // [ "en-US", "pt-BR", ... ]
```

---
_Source: https://npm.io/package/prodap-lore-locale · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
