lingo.dev 0.92.19 → 0.93.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +19 -123
- package/build/cli.cjs +43 -1
- package/build/cli.cjs.map +1 -1
- package/build/cli.mjs +43 -1
- package/build/cli.mjs.map +1 -1
- package/build/compiler.cjs +8 -0
- package/build/compiler.cjs.map +1 -0
- package/build/compiler.d.cts +2 -0
- package/build/compiler.d.ts +2 -0
- package/build/compiler.mjs +6 -0
- package/build/compiler.mjs.map +1 -0
- package/build/react/client.cjs +3 -0
- package/build/react/client.cjs.map +1 -0
- package/build/react/client.d.cts +1 -0
- package/build/react/client.d.ts +1 -0
- package/build/react/client.mjs +3 -0
- package/build/react/client.mjs.map +1 -0
- package/build/react/react-router.cjs +3 -0
- package/build/react/react-router.cjs.map +1 -0
- package/build/react/react-router.d.cts +1 -0
- package/build/react/react-router.d.ts +1 -0
- package/build/react/react-router.mjs +3 -0
- package/build/react/react-router.mjs.map +1 -0
- package/build/react/rsc.cjs +3 -0
- package/build/react/rsc.cjs.map +1 -0
- package/build/react/rsc.d.cts +1 -0
- package/build/react/rsc.d.ts +1 -0
- package/build/react/rsc.mjs +3 -0
- package/build/react/rsc.mjs.map +1 -0
- package/build/react.cjs +3 -0
- package/build/react.cjs.map +1 -0
- package/build/react.d.cts +1 -0
- package/build/react.d.ts +1 -0
- package/build/react.mjs +3 -0
- package/build/react.mjs.map +1 -0
- package/build/sdk.d.cts +5 -0
- package/build/sdk.d.ts +5 -0
- package/package.json +45 -3
package/README.md
CHANGED
|
@@ -1,20 +1,22 @@
|
|
|
1
|
+
> [!NOTE]
|
|
2
|
+
> **Introducing: Lingo.dev Compiler** - Make any React app multilingual at build time without changing your components. [Read the docs](https://lingo.dev/compiler).
|
|
3
|
+
|
|
1
4
|
<p align="center">
|
|
2
|
-
<a href="https://lingo.dev">
|
|
3
|
-
<img src="https://raw.githubusercontent.com/lingodotdev/lingo.dev/main/content/banner.
|
|
5
|
+
<a href="https://lingo.dev/compiler">
|
|
6
|
+
<img src="https://raw.githubusercontent.com/lingodotdev/lingo.dev/main/content/banner.compiler.png" width="100%" alt="Lingo.dev" />
|
|
4
7
|
</a>
|
|
5
8
|
</p>
|
|
6
9
|
|
|
7
10
|
<p align="center">
|
|
8
|
-
<strong>⚡️ AI-powered open-source
|
|
11
|
+
<strong>⚡️ AI-powered open-source tools for web & mobile localization.</strong>
|
|
9
12
|
</p>
|
|
10
13
|
|
|
11
14
|
<br />
|
|
12
15
|
|
|
13
16
|
<p align="center">
|
|
14
|
-
<a href="https://
|
|
15
|
-
<a href="https://
|
|
16
|
-
<a href="
|
|
17
|
-
<a href="#">Star the repo</a>
|
|
17
|
+
<a href="https://lingo.dev/cli">Lingo.dev CLI</a> •
|
|
18
|
+
<a href="https://lingo.dev/ci">Lingo.dev CI/CD</a> •
|
|
19
|
+
<a href="https://lingo.dev/compiler">Lingo.dev Compiler 🆕</a>
|
|
18
20
|
</p>
|
|
19
21
|
|
|
20
22
|
<p align="center">
|
|
@@ -31,125 +33,15 @@
|
|
|
31
33
|
|
|
32
34
|
<br />
|
|
33
35
|
|
|
34
|
-
Lingo.dev is
|
|
35
|
-
|
|
36
|
-
Lingo.dev is designed to produce authentic translations instantly, eliminating manual work and management overhead. As a result, teams do accurate localization 100x faster, shipping features to more happy users worldwide. It can be used with your own LLM or with Lingo.dev-managed Localization Engine.
|
|
37
|
-
|
|
38
|
-
> **Little-known fact:** Lingo.dev began as a small project at a student hackathon back in 2023! Many iterations later, we got accepted into Y Combinator in 2024, and we're now hiring! Interested in building the next-gen localization tools? Send your CV to careers@lingo.dev! 🚀
|
|
39
|
-
|
|
40
|
-
## 📑 In This Guide
|
|
41
|
-
|
|
42
|
-
- [Quickstart](#-quickstart) - Get started in minutes
|
|
43
|
-
- [Caching](#-caching-with-i18nlock) - Optimize translation updates
|
|
44
|
-
- [GitHub Action](#-github-action) - Automate localization in CI/CD
|
|
45
|
-
- [Features](#-supercharged-features) - What makes Lingo.dev powerful
|
|
46
|
-
- [Documentation](#-documentation) - Detailed guides and references
|
|
47
|
-
- [Contribute](#-contribute) - Join our community
|
|
48
|
-
|
|
49
|
-
## 💫 Quickstart
|
|
50
|
-
|
|
51
|
-
Lingo.dev CLI is designed to work with both your own LLM, and Lingo.dev-managed Localization Engine built on top of latest SOTA (state-of-the-art) LLMs.
|
|
52
|
-
|
|
53
|
-
### Using Your Own LLM (BYOK or Bring Your Own Key)
|
|
54
|
-
|
|
55
|
-
1. Create an `i18n.json` configuration file:
|
|
56
|
-
|
|
57
|
-
```json
|
|
58
|
-
{
|
|
59
|
-
"version": 1.5,
|
|
60
|
-
"provider": {
|
|
61
|
-
"id": "anthropic",
|
|
62
|
-
"model": "claude-3-7-sonnet-latest",
|
|
63
|
-
"prompt": "You're translating text from {source} to {target}."
|
|
64
|
-
},
|
|
65
|
-
"locale": {
|
|
66
|
-
"source": "en",
|
|
67
|
-
"targets": ["es", "fr", "de"]
|
|
68
|
-
}
|
|
69
|
-
}
|
|
70
|
-
```
|
|
71
|
-
|
|
72
|
-
2. Set your API key as an environment variable:
|
|
73
|
-
|
|
74
|
-
```bash
|
|
75
|
-
export ANTHROPIC_API_KEY=your_anthropic_api_key
|
|
76
|
-
# or for OpenAI
|
|
77
|
-
export OPENAI_API_KEY=your_openai_api_key
|
|
78
|
-
```
|
|
79
|
-
|
|
80
|
-
3. Run the localization:
|
|
81
|
-
|
|
82
|
-
```bash
|
|
83
|
-
npx lingo.dev@latest i18n
|
|
84
|
-
```
|
|
85
|
-
|
|
86
|
-
### Using Lingo.dev Cloud
|
|
87
|
-
|
|
88
|
-
Oftentimes, production-grade apps require features like translation memory, glossary support, and localization quality assurance. Also, sometimes, you want an expert to decide for you which LLM provider and model to use, and to update the model automatically when new ones are released. Lingo.dev is a managed Localization Engine that provides these features:
|
|
89
|
-
|
|
90
|
-
1. Create an `i18n.json` configuration file (without provider node):
|
|
36
|
+
Lingo.dev is an open-source, i18n toolkit designed to help use LLMs for localization and translation of web, mobile apps and markdown content.
|
|
91
37
|
|
|
92
|
-
|
|
93
|
-
{
|
|
94
|
-
"version": 1.5,
|
|
95
|
-
"locale": {
|
|
96
|
-
"source": "en",
|
|
97
|
-
"targets": ["es", "fr", "de"]
|
|
98
|
-
}
|
|
99
|
-
}
|
|
100
|
-
```
|
|
38
|
+
Lingo.dev includes:
|
|
101
39
|
|
|
102
|
-
|
|
40
|
+
- **Lingo.dev CLI** - a CLI tool built to help translate apps and markdown content with lightning speed and accuracy. [Docs](https://lingo.dev/cli)
|
|
41
|
+
- **Lingo.dev CI/CD** - a CI/CD integration for GitHub, GitLab, and Bitbucket built to keep translations up-to-date automatically as soon as new content is added. [Docs](https://lingo.dev/ci)
|
|
42
|
+
- **Lingo.dev Compiler 🆕** - makes React app multilingual at build time without requiring changes to your existing components. [Docs](https://lingo.dev/compiler)
|
|
103
43
|
|
|
104
|
-
|
|
105
|
-
npx lingo.dev@latest auth --login
|
|
106
|
-
```
|
|
107
|
-
|
|
108
|
-
3. Run localization:
|
|
109
|
-
|
|
110
|
-
```bash
|
|
111
|
-
npx lingo.dev@latest i18n
|
|
112
|
-
```
|
|
113
|
-
|
|
114
|
-
## 📖 Documentation
|
|
115
|
-
|
|
116
|
-
For detailed guides and API references, visit the [documentation](https://lingo.dev/go/docs).
|
|
117
|
-
|
|
118
|
-
## 🔒 Caching with `i18n.lock`
|
|
119
|
-
|
|
120
|
-
Lingo.dev uses an `i18n.lock` file to track content checksums, ensuring only changed text gets translated. This improves:
|
|
121
|
-
|
|
122
|
-
- ⚡️ **Speed**: Skip already translated content
|
|
123
|
-
- 🔄 **Consistency**: Prevent unnecessary retranslations
|
|
124
|
-
- 💰 **Cost**: No billing for repeated translations
|
|
125
|
-
|
|
126
|
-
## 🤖 GitHub Action
|
|
127
|
-
|
|
128
|
-
Lingo.dev offers a GitHub Action to automate localization in your CI/CD pipeline. Here's a basic setup:
|
|
129
|
-
|
|
130
|
-
```yaml
|
|
131
|
-
- uses: lingodotdev/lingo.dev@main
|
|
132
|
-
with:
|
|
133
|
-
api-key: ${{ secrets.LINGODOTDEV_API_KEY }}
|
|
134
|
-
```
|
|
135
|
-
|
|
136
|
-
This action runs `lingo.dev i18n` on every push, keeping your translations up-to-date automatically.
|
|
137
|
-
|
|
138
|
-
For pull request mode and other configuration options, visit our [GitHub Action documentation](https://docs.lingo.dev/ci-action/gha).
|
|
139
|
-
|
|
140
|
-
## ⚡️ Lingo.dev's Superpowers
|
|
141
|
-
|
|
142
|
-
- 🔥 **Instant integration**: Works with your codebase in minutes
|
|
143
|
-
- 🔄 **CI/CD Automation**: Set it and forget it
|
|
144
|
-
- 🌍 **Global reach**: Ship to users everywhere
|
|
145
|
-
- 🧠 **AI-powered**: Uses latest language models for natural translations
|
|
146
|
-
- 📊 **Format-agnostic**: JSON, YAML, CSV, Markdown, Android, iOS, and many more
|
|
147
|
-
- 🔍 **Clean diffs**: Preserves your file structure exactly
|
|
148
|
-
- ⚡️ **Lightning-fast**: Translations in seconds, not days
|
|
149
|
-
- 🔄 **Always synced**: Automatically updates when content changes
|
|
150
|
-
- 🌟 **Human quality**: Translations that don't sound robotic
|
|
151
|
-
- 👨💻 **Built by devs, for devs**: We use it ourselves daily
|
|
152
|
-
- 📈 **Grows with you**: From side project to enterprise scale
|
|
44
|
+
All tools are designed to help use LLM models for precise translation and localization, and to eliminate manual work.
|
|
153
45
|
|
|
154
46
|
## 🤝 Contribute
|
|
155
47
|
|
|
@@ -175,3 +67,7 @@ Want to contribute? Create a pull request!
|
|
|
175
67
|
- [Bengali](/readme/bn.md)
|
|
176
68
|
|
|
177
69
|
Don't see your language? Just add a new language code to the [`i18n.json`](./i18n.json) file and open a PR!
|
|
70
|
+
|
|
71
|
+
## 💬 Talk to us
|
|
72
|
+
|
|
73
|
+
Have feedback, feature requests, bug reports or other suggestions? [Talk to us on Discord!](https://lingo.dev/go/discord)
|
package/build/cli.cjs
CHANGED
|
@@ -6580,7 +6580,7 @@ async function renderHero() {
|
|
|
6580
6580
|
// package.json
|
|
6581
6581
|
var package_default = {
|
|
6582
6582
|
name: "lingo.dev",
|
|
6583
|
-
version: "0.
|
|
6583
|
+
version: "0.93.1",
|
|
6584
6584
|
description: "Lingo.dev CLI",
|
|
6585
6585
|
private: false,
|
|
6586
6586
|
publishConfig: {
|
|
@@ -6603,6 +6603,31 @@ var package_default = {
|
|
|
6603
6603
|
types: "./build/spec.d.ts",
|
|
6604
6604
|
import: "./build/spec.mjs",
|
|
6605
6605
|
require: "./build/spec.cjs"
|
|
6606
|
+
},
|
|
6607
|
+
"./compiler": {
|
|
6608
|
+
types: "./build/compiler.d.ts",
|
|
6609
|
+
import: "./build/compiler.mjs",
|
|
6610
|
+
require: "./build/compiler.cjs"
|
|
6611
|
+
},
|
|
6612
|
+
"./react": {
|
|
6613
|
+
types: "./build/react.d.ts",
|
|
6614
|
+
import: "./build/react.mjs",
|
|
6615
|
+
require: "./build/react.cjs"
|
|
6616
|
+
},
|
|
6617
|
+
"./react/client": {
|
|
6618
|
+
types: "./build/react/client.d.ts",
|
|
6619
|
+
import: "./build/react/client.mjs",
|
|
6620
|
+
require: "./build/react/client.cjs"
|
|
6621
|
+
},
|
|
6622
|
+
"./react/rsc": {
|
|
6623
|
+
types: "./build/react/rsc.d.ts",
|
|
6624
|
+
import: "./build/react/rsc.mjs",
|
|
6625
|
+
require: "./build/react/rsc.cjs"
|
|
6626
|
+
},
|
|
6627
|
+
"./react/react-router": {
|
|
6628
|
+
types: "./build/react/react-router.d.ts",
|
|
6629
|
+
import: "./build/react/react-router.mjs",
|
|
6630
|
+
require: "./build/react/react-router.cjs"
|
|
6606
6631
|
}
|
|
6607
6632
|
},
|
|
6608
6633
|
typesVersions: {
|
|
@@ -6615,6 +6640,21 @@ var package_default = {
|
|
|
6615
6640
|
],
|
|
6616
6641
|
spec: [
|
|
6617
6642
|
"./build/spec.d.ts"
|
|
6643
|
+
],
|
|
6644
|
+
compiler: [
|
|
6645
|
+
"./build/compiler.d.ts"
|
|
6646
|
+
],
|
|
6647
|
+
react: [
|
|
6648
|
+
"./build/react.d.ts"
|
|
6649
|
+
],
|
|
6650
|
+
"react/client": [
|
|
6651
|
+
"./build/react/client.d.ts"
|
|
6652
|
+
],
|
|
6653
|
+
"react/rsc": [
|
|
6654
|
+
"./build/react/rsc.d.ts"
|
|
6655
|
+
],
|
|
6656
|
+
"react/react-router": [
|
|
6657
|
+
"./build/react/react-router.d.ts"
|
|
6618
6658
|
]
|
|
6619
6659
|
}
|
|
6620
6660
|
},
|
|
@@ -6649,6 +6689,8 @@ var package_default = {
|
|
|
6649
6689
|
"@inquirer/prompts": "^7.4.1",
|
|
6650
6690
|
"@lingo.dev/_sdk": "workspace:*",
|
|
6651
6691
|
"@lingo.dev/_spec": "workspace:*",
|
|
6692
|
+
"@lingo.dev/_react": "workspace:*",
|
|
6693
|
+
"@lingo.dev/_compiler": "workspace:*",
|
|
6652
6694
|
"@modelcontextprotocol/sdk": "^1.5.0",
|
|
6653
6695
|
"@paralleldrive/cuid2": "^2.2.2",
|
|
6654
6696
|
ai: "^4.3.15",
|