@discord/intl 0.10.0-rc.3 → 0.10.0-rc.4
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/dist/message-loader.js +1 -1
- package/package.json +2 -2
- package/src/message-loader.ts +1 -1
package/dist/message-loader.js
CHANGED
|
@@ -109,7 +109,7 @@ class MessageLoader {
|
|
|
109
109
|
getBinds() {
|
|
110
110
|
const onChange = this.onChange.bind(this);
|
|
111
111
|
const result = {};
|
|
112
|
-
for (const key
|
|
112
|
+
for (const key of this.messageKeys) {
|
|
113
113
|
const bound = (locale) => this.get(key, locale);
|
|
114
114
|
bound.onChange = onChange;
|
|
115
115
|
result[key] = bound;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@discord/intl",
|
|
3
|
-
"version": "0.10.0-rc.
|
|
3
|
+
"version": "0.10.0-rc.4",
|
|
4
4
|
"license": "MIT",
|
|
5
5
|
"description": "Client runtime for managing messages and translations in a React project.",
|
|
6
6
|
"main": "./dist/index.js",
|
|
@@ -19,7 +19,7 @@
|
|
|
19
19
|
"@formatjs/intl": "^2.10.1",
|
|
20
20
|
"@intrnl/xxhash64": "^0.1.2",
|
|
21
21
|
"intl-messageformat": "^10.5.11",
|
|
22
|
-
"@discord/intl-ast": "0.10.0-rc.
|
|
22
|
+
"@discord/intl-ast": "0.10.0-rc.4"
|
|
23
23
|
},
|
|
24
24
|
"devDependencies": {
|
|
25
25
|
"@swc/cli": "^0.3.12",
|
package/src/message-loader.ts
CHANGED
|
@@ -195,7 +195,7 @@ export class MessageLoader {
|
|
|
195
195
|
getBinds(): Record<string, IntlMessageGetter> {
|
|
196
196
|
const onChange = this.onChange.bind(this);
|
|
197
197
|
const result: Record<string, IntlMessageGetter> = {};
|
|
198
|
-
for (const key
|
|
198
|
+
for (const key of this.messageKeys) {
|
|
199
199
|
const bound = (locale: LocaleId) => this.get(key, locale);
|
|
200
200
|
bound.onChange = onChange;
|
|
201
201
|
result[key] = bound;
|