lingo.dev 0.93.5 → 0.93.7
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 +95 -42
- package/build/cli.cjs +2083 -2033
- package/build/cli.cjs.map +1 -1
- package/build/cli.mjs +2073 -2023
- package/build/cli.mjs.map +1 -1
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -1,22 +1,20 @@
|
|
|
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
|
-
|
|
4
1
|
<p align="center">
|
|
5
|
-
<a href="https://lingo.dev
|
|
2
|
+
<a href="https://lingo.dev">
|
|
6
3
|
<img src="https://raw.githubusercontent.com/lingodotdev/lingo.dev/main/content/banner.compiler.png" width="100%" alt="Lingo.dev" />
|
|
7
4
|
</a>
|
|
8
5
|
</p>
|
|
9
6
|
|
|
10
7
|
<p align="center">
|
|
11
|
-
<strong>⚡️ AI-powered open-source
|
|
8
|
+
<strong>⚡️ AI-powered, open-source i18n toolkit for instant localization with LLMs.</strong>
|
|
12
9
|
</p>
|
|
13
10
|
|
|
14
11
|
<br />
|
|
15
12
|
|
|
16
13
|
<p align="center">
|
|
14
|
+
<a href="https://lingo.dev/compiler">Lingo.dev Compiler</a> •
|
|
17
15
|
<a href="https://lingo.dev/cli">Lingo.dev CLI</a> •
|
|
18
16
|
<a href="https://lingo.dev/ci">Lingo.dev CI/CD</a> •
|
|
19
|
-
<a href="https://lingo.dev/
|
|
17
|
+
<a href="https://lingo.dev/sdk">Lingo.dev SDK</a>
|
|
20
18
|
</p>
|
|
21
19
|
|
|
22
20
|
<p align="center">
|
|
@@ -31,61 +29,116 @@
|
|
|
31
29
|
</a>
|
|
32
30
|
</p>
|
|
33
31
|
|
|
34
|
-
|
|
32
|
+
---
|
|
35
33
|
|
|
36
|
-
|
|
34
|
+
## Meet the Compiler 🆕
|
|
37
35
|
|
|
38
|
-
Lingo.dev
|
|
36
|
+
**Lingo.dev Compiler** is a free, open-source compiler middleware, designed to make any React app multilingual at build time without requiring any changes to the existing React components.
|
|
39
37
|
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
38
|
+
```bash
|
|
39
|
+
# install once
|
|
40
|
+
npm install lingo.dev
|
|
43
41
|
|
|
44
|
-
|
|
42
|
+
# next.config.js
|
|
43
|
+
import lingoCompiler from "lingo.dev/compiler";
|
|
45
44
|
|
|
46
|
-
|
|
45
|
+
export default lingoCompiler.next({
|
|
46
|
+
sourceLocale: "en",
|
|
47
|
+
targetLocales: ["es", "fr"],
|
|
48
|
+
});
|
|
49
|
+
```
|
|
47
50
|
|
|
48
|
-
|
|
51
|
+
Run `next build` and watch Spanish and French bundles pop out ✨
|
|
49
52
|
|
|
50
|
-
[
|
|
53
|
+
[Read the docs →](https://lingo.dev/compiler) for the full guide.
|
|
51
54
|
|
|
52
|
-
|
|
55
|
+
---
|
|
53
56
|
|
|
54
|
-
|
|
57
|
+
### What's inside this repo?
|
|
55
58
|
|
|
56
|
-
|
|
59
|
+
| Tool | TL;DR | Docs |
|
|
60
|
+
| ------------ | ------------------------------------------------------------------------------ | --------------------------------------- |
|
|
61
|
+
| **Compiler** | Build-time React localization | [/compiler](https://lingo.dev/compiler) |
|
|
62
|
+
| **CLI** | One-command localization for web and mobile apps, JSON, YAML, markdown, + more | [/cli](https://lingo.dev/cli) |
|
|
63
|
+
| **CI/CD** | Auto-commit translations on every push + create pull requests if needed | [/ci](https://lingo.dev/ci) |
|
|
64
|
+
| **SDK** | Realtime translation for user-generated content | [/sdk](https://lingo.dev/sdk) |
|
|
57
65
|
|
|
58
|
-
|
|
66
|
+
Below are the quick hits for each 👇
|
|
59
67
|
|
|
60
|
-
|
|
68
|
+
---
|
|
61
69
|
|
|
62
|
-
|
|
70
|
+
### ⚡️ Lingo.dev CLI
|
|
63
71
|
|
|
64
|
-
|
|
72
|
+
Translate code & content straight from your terminal.
|
|
65
73
|
|
|
66
|
-
|
|
74
|
+
```bash
|
|
75
|
+
npx lingo.dev@latest i18n
|
|
76
|
+
```
|
|
67
77
|
|
|
68
|
-
|
|
78
|
+
It fingerprints every string, caches results, and only re-translates what changed.
|
|
69
79
|
|
|
70
|
-
|
|
80
|
+
[Read the docs →](https://lingo.dev/cli)
|
|
71
81
|
|
|
72
|
-
|
|
82
|
+
---
|
|
83
|
+
|
|
84
|
+
### 🔄 Lingo.dev CI/CD
|
|
85
|
+
|
|
86
|
+
Ship perfect translations automatically.
|
|
87
|
+
|
|
88
|
+
```yaml
|
|
89
|
+
# .github/workflows/i18n.yml
|
|
90
|
+
name: Lingo.dev i18n
|
|
91
|
+
on: [push]
|
|
92
|
+
|
|
93
|
+
jobs:
|
|
94
|
+
i18n:
|
|
95
|
+
runs-on: ubuntu-latest
|
|
96
|
+
steps:
|
|
97
|
+
- uses: actions/checkout@v4
|
|
98
|
+
- uses: lingodotdev/lingo.dev@main
|
|
99
|
+
with:
|
|
100
|
+
api-key: ${{ secrets.LINGODOTDEV_API_KEY }}
|
|
101
|
+
```
|
|
102
|
+
|
|
103
|
+
Keeps your repo green and your product multilingual without the manual steps.
|
|
104
|
+
|
|
105
|
+
[Read the docs →](https://lingo.dev/ci)
|
|
106
|
+
|
|
107
|
+
---
|
|
108
|
+
|
|
109
|
+
### 🧩 Lingo.dev SDK
|
|
110
|
+
|
|
111
|
+
Instant per-request translation for dynamic content.
|
|
73
112
|
|
|
113
|
+
```ts
|
|
114
|
+
import { translate } from "lingo.dev/sdk";
|
|
115
|
+
|
|
116
|
+
const text = await translate("Hello world", { to: "es" });
|
|
117
|
+
// → "¡Hola mundo!"
|
|
118
|
+
```
|
|
119
|
+
|
|
120
|
+
Perfect for chat, user comments, and other real-time flows.
|
|
121
|
+
|
|
122
|
+
[Read the docs →](https://lingo.dev/sdk)
|
|
123
|
+
|
|
124
|
+
---
|
|
125
|
+
|
|
126
|
+
## 🤝 Community
|
|
127
|
+
|
|
128
|
+
We're community-driven and love contributions!
|
|
129
|
+
|
|
130
|
+
- Got an idea? [Open an issue](https://github.com/lingodotdev/lingo.dev/issues)
|
|
131
|
+
- Want to fix something? [Send a PR](https://github.com/lingodotdev/lingo.dev/pulls)
|
|
132
|
+
- Need help? [Join our Discord](https://lingo.dev/go/discord)
|
|
133
|
+
|
|
134
|
+
## ⭐ Star History
|
|
135
|
+
|
|
136
|
+
If you like what we're doing, give us a ⭐ and help us reach 3,000 stars! 🌟
|
|
137
|
+
|
|
138
|
+
[](https://www.star-history.com/#lingodotdev/lingo.dev&Date)
|
|
74
139
|
|
|
75
140
|
## 🌐 Readme in other languages
|
|
76
141
|
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
- [Korean](/readme/ko.md)
|
|
81
|
-
- [Spanish](/readme/es.md)
|
|
82
|
-
- [French](/readme/fr.md)
|
|
83
|
-
- [Russian](/readme/ru.md)
|
|
84
|
-
- [German](/readme/de.md)
|
|
85
|
-
- [Italian](/readme/it.md)
|
|
86
|
-
- [Arabic](/readme/ar.md)
|
|
87
|
-
- [Hindi](/readme/hi.md)
|
|
88
|
-
- [Bengali](/readme/bn.md)
|
|
89
|
-
- [Farsi](/readme/fa.md)
|
|
90
|
-
|
|
91
|
-
Don't see your language? Just add a new language code to the [`i18n.json`](./i18n.json) file and open a PR!
|
|
142
|
+
[English](https://github.com/lingodotdev/lingo.dev) • [中文](/readme/zh-Hans.md) • [日本語](/readme/ja.md) • [한국어](/readme/ko.md) • [Español](/readme/es.md) • [Français](/readme/fr.md) • [Русский](/readme/ru.md) • [Deutsch](/readme/de.md) • [Italiano](/readme/it.md) • [العربية](/readme/ar.md) • [हिन्दी](/readme/hi.md) • [বাংলা](/readme/bn.md) • [فارسی](/readme/fa.md)
|
|
143
|
+
|
|
144
|
+
Don't see your language? Add it to [`i18n.json`](./i18n.json) and open a PR!
|