gt-node 0.6.13 → 0.7.0
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/CHANGELOG.md +19 -0
- package/README.md +1 -1
- package/dist/index.cjs +6 -0
- package/dist/index.d.cts +3 -3
- package/dist/index.d.mts +3 -3
- package/dist/index.mjs +2 -2
- package/dist/{types-BA-INDkb.d.mts → types-D2TZTLXG.d.mts} +3 -3
- package/dist/{types-Ctyskm8X.d.cts → types-DsauAGkA.d.cts} +3 -3
- package/dist/types.d.cts +1 -1
- package/dist/types.d.mts +1 -1
- package/package.json +5 -4
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,24 @@
|
|
|
1
1
|
# gt-node
|
|
2
2
|
|
|
3
|
+
## 0.7.0
|
|
4
|
+
|
|
5
|
+
### Minor Changes
|
|
6
|
+
|
|
7
|
+
- [#1359](https://github.com/generaltranslation/gt/pull/1359) [`528bb4a`](https://github.com/generaltranslation/gt/commit/528bb4a34b3eeab6f676137ab0f09e85dff213b0) Thanks [@ErnestM1234](https://github.com/ErnestM1234)! - Enable dictionary-backed getTranslations with t and t.obj, and expose it from gt-node.
|
|
8
|
+
|
|
9
|
+
### Patch Changes
|
|
10
|
+
|
|
11
|
+
- Updated dependencies [[`663af94`](https://github.com/generaltranslation/gt/commit/663af94207bc244de30046d96130e913f48c9add), [`a88c86d`](https://github.com/generaltranslation/gt/commit/a88c86df7842299063f1a2f6f7404e021c905016), [`0f252ff`](https://github.com/generaltranslation/gt/commit/0f252fff408c701811cba61565beaf15bf9cdd95), [`ee3a6ee`](https://github.com/generaltranslation/gt/commit/ee3a6eea113fbc5c2f5f0e8771d878a305f7bc7f), [`375d75f`](https://github.com/generaltranslation/gt/commit/375d75f7a6525d83e19a5cf015a375a0f50537d2), [`528bb4a`](https://github.com/generaltranslation/gt/commit/528bb4a34b3eeab6f676137ab0f09e85dff213b0), [`9eae4d9`](https://github.com/generaltranslation/gt/commit/9eae4d93476688b621c739683c8bac64cbf50bf0), [`e123485`](https://github.com/generaltranslation/gt/commit/e12348563700ed886f64b2e00d7964355fb4558a), [`40e26b9`](https://github.com/generaltranslation/gt/commit/40e26b914295101d1be00f738fc33eb4ba9c495a)]:
|
|
12
|
+
- gt-i18n@0.9.0
|
|
13
|
+
- generaltranslation@8.2.12
|
|
14
|
+
|
|
15
|
+
## 0.6.14
|
|
16
|
+
|
|
17
|
+
### Patch Changes
|
|
18
|
+
|
|
19
|
+
- Updated dependencies [[`cb2e106`](https://github.com/generaltranslation/gt/commit/cb2e1066f975dce8e90b166c51f763a3778c3861), [`b907d87`](https://github.com/generaltranslation/gt/commit/b907d8799670e9e22355b5664da4c9f6f323b8f4), [`bf0386b`](https://github.com/generaltranslation/gt/commit/bf0386b38b8a9342619eb2f8b4e5f043dcba4d8f)]:
|
|
20
|
+
- gt-i18n@0.8.14
|
|
21
|
+
|
|
3
22
|
## 0.6.13
|
|
4
23
|
|
|
5
24
|
### Patch Changes
|
package/README.md
CHANGED
|
@@ -18,7 +18,7 @@ pnpm add gt-node
|
|
|
18
18
|
## Usage
|
|
19
19
|
|
|
20
20
|
```typescript
|
|
21
|
-
import { /* utilities */
|
|
21
|
+
import {} from /* utilities */ 'gt-node';
|
|
22
22
|
```
|
|
23
23
|
|
|
24
24
|
This package provides Node.js-specific utilities built on top of the General Translation toolkit. It includes all functionality from:
|
package/dist/index.cjs
CHANGED
|
@@ -149,6 +149,12 @@ Object.defineProperty(exports, "getMessages", {
|
|
|
149
149
|
}
|
|
150
150
|
});
|
|
151
151
|
exports.getRequestLocale = getRequestLocale;
|
|
152
|
+
Object.defineProperty(exports, "getTranslations", {
|
|
153
|
+
enumerable: true,
|
|
154
|
+
get: function() {
|
|
155
|
+
return gt_i18n_internal.getTranslations;
|
|
156
|
+
}
|
|
157
|
+
});
|
|
152
158
|
Object.defineProperty(exports, "getVersionId", {
|
|
153
159
|
enumerable: true,
|
|
154
160
|
get: function() {
|
package/dist/index.d.cts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { n as InitializeGTParams } from "./types-
|
|
1
|
+
import { n as InitializeGTParams } from "./types-DsauAGkA.cjs";
|
|
2
2
|
import { declareStatic, declareVar, decodeMsg, decodeOptions, decodeVars, derive, getDefaultLocale, getLocale, getLocaleProperties, getLocales, getVersionId, msg } from "gt-i18n";
|
|
3
|
-
import { getGT, getMessages, tx } from "gt-i18n/internal";
|
|
3
|
+
import { getGT, getMessages, getTranslations, tx } from "gt-i18n/internal";
|
|
4
4
|
|
|
5
5
|
//#region src/setup/initializeGT.d.ts
|
|
6
6
|
/**
|
|
@@ -44,5 +44,5 @@ interface RequestLike {
|
|
|
44
44
|
*/
|
|
45
45
|
declare function getRequestLocale(request: RequestLike): string;
|
|
46
46
|
//#endregion
|
|
47
|
-
export { declareStatic, declareVar, decodeMsg, decodeOptions, decodeVars, derive, getDefaultLocale, getGT, getLocale, getLocaleProperties, getLocales, getMessages, getRequestLocale, getVersionId, initializeGT, msg, tx, withGT };
|
|
47
|
+
export { declareStatic, declareVar, decodeMsg, decodeOptions, decodeVars, derive, getDefaultLocale, getGT, getLocale, getLocaleProperties, getLocales, getMessages, getRequestLocale, getTranslations, getVersionId, initializeGT, msg, tx, withGT };
|
|
48
48
|
//# sourceMappingURL=index.d.cts.map
|
package/dist/index.d.mts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { n as InitializeGTParams } from "./types-
|
|
2
|
-
import { getGT, getMessages, tx } from "gt-i18n/internal";
|
|
1
|
+
import { n as InitializeGTParams } from "./types-D2TZTLXG.mjs";
|
|
2
|
+
import { getGT, getMessages, getTranslations, tx } from "gt-i18n/internal";
|
|
3
3
|
import { declareStatic, declareVar, decodeMsg, decodeOptions, decodeVars, derive, getDefaultLocale, getLocale, getLocaleProperties, getLocales, getVersionId, msg } from "gt-i18n";
|
|
4
4
|
|
|
5
5
|
//#region src/setup/initializeGT.d.ts
|
|
@@ -44,5 +44,5 @@ interface RequestLike {
|
|
|
44
44
|
*/
|
|
45
45
|
declare function getRequestLocale(request: RequestLike): string;
|
|
46
46
|
//#endregion
|
|
47
|
-
export { declareStatic, declareVar, decodeMsg, decodeOptions, decodeVars, derive, getDefaultLocale, getGT, getLocale, getLocaleProperties, getLocales, getMessages, getRequestLocale, getVersionId, initializeGT, msg, tx, withGT };
|
|
47
|
+
export { declareStatic, declareVar, decodeMsg, decodeOptions, decodeVars, derive, getDefaultLocale, getGT, getLocale, getLocaleProperties, getLocales, getMessages, getRequestLocale, getTranslations, getVersionId, initializeGT, msg, tx, withGT };
|
|
48
48
|
//# sourceMappingURL=index.d.mts.map
|
package/dist/index.mjs
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { n as getAsyncConditionStore, r as setAsyncConditionStore, t as AsyncConditionStore } from "./AsyncConditionStore-CgVuzOnG.mjs";
|
|
2
|
-
import { I18nManager, getGT, getI18nManager, getMessages, setI18nManager, tx } from "gt-i18n/internal";
|
|
2
|
+
import { I18nManager, getGT, getI18nManager, getMessages, getTranslations, setI18nManager, tx } from "gt-i18n/internal";
|
|
3
3
|
import { declareStatic, declareVar, decodeMsg, decodeOptions, decodeVars, derive, getDefaultLocale, getLocale, getLocaleProperties, getLocales, getVersionId, msg } from "gt-i18n";
|
|
4
4
|
//#region src/setup/initializeGT.ts
|
|
5
5
|
/**
|
|
@@ -75,6 +75,6 @@ function getRequestLocale(request) {
|
|
|
75
75
|
return gtInstance.determineLocale(preferredLocales) || defaultLocale;
|
|
76
76
|
}
|
|
77
77
|
//#endregion
|
|
78
|
-
export { declareStatic, declareVar, decodeMsg, decodeOptions, decodeVars, derive, getDefaultLocale, getGT, getLocale, getLocaleProperties, getLocales, getMessages, getRequestLocale, getVersionId, initializeGT, msg, tx, withGT };
|
|
78
|
+
export { declareStatic, declareVar, decodeMsg, decodeOptions, decodeVars, derive, getDefaultLocale, getGT, getLocale, getLocaleProperties, getLocales, getMessages, getRequestLocale, getTranslations, getVersionId, initializeGT, msg, tx, withGT };
|
|
79
79
|
|
|
80
80
|
//# sourceMappingURL=index.mjs.map
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { GTConfig, GTConfig as GTConfig$1, TranslationsLoader, TranslationsLoader as TranslationsLoader$1 } from "gt-i18n/internal/types";
|
|
1
|
+
import { DictionaryConfig, GTConfig, GTConfig as GTConfig$1, TranslationsLoader, TranslationsLoader as TranslationsLoader$1 } from "gt-i18n/internal/types";
|
|
2
2
|
|
|
3
3
|
//#region src/setup/types.d.ts
|
|
4
4
|
/**
|
|
@@ -7,9 +7,9 @@ import { GTConfig, GTConfig as GTConfig$1, TranslationsLoader, TranslationsLoade
|
|
|
7
7
|
* @param {string[]} params.locales - The locales to support
|
|
8
8
|
* @param {object} params.loadTranslations - The custom translation loader to use
|
|
9
9
|
*/
|
|
10
|
-
type InitializeGTParams = GTConfig & {
|
|
10
|
+
type InitializeGTParams = DictionaryConfig & GTConfig & {
|
|
11
11
|
loadTranslations?: TranslationsLoader;
|
|
12
12
|
};
|
|
13
13
|
//#endregion
|
|
14
14
|
export { InitializeGTParams as n, TranslationsLoader$1 as r, GTConfig$1 as t };
|
|
15
|
-
//# sourceMappingURL=types-
|
|
15
|
+
//# sourceMappingURL=types-D2TZTLXG.d.mts.map
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { GTConfig, GTConfig as GTConfig$1, TranslationsLoader, TranslationsLoader as TranslationsLoader$1 } from "gt-i18n/internal/types";
|
|
1
|
+
import { DictionaryConfig, GTConfig, GTConfig as GTConfig$1, TranslationsLoader, TranslationsLoader as TranslationsLoader$1 } from "gt-i18n/internal/types";
|
|
2
2
|
|
|
3
3
|
//#region src/setup/types.d.ts
|
|
4
4
|
/**
|
|
@@ -7,9 +7,9 @@ import { GTConfig, GTConfig as GTConfig$1, TranslationsLoader, TranslationsLoade
|
|
|
7
7
|
* @param {string[]} params.locales - The locales to support
|
|
8
8
|
* @param {object} params.loadTranslations - The custom translation loader to use
|
|
9
9
|
*/
|
|
10
|
-
type InitializeGTParams = GTConfig & {
|
|
10
|
+
type InitializeGTParams = DictionaryConfig & GTConfig & {
|
|
11
11
|
loadTranslations?: TranslationsLoader;
|
|
12
12
|
};
|
|
13
13
|
//#endregion
|
|
14
14
|
export { InitializeGTParams as n, TranslationsLoader$1 as r, GTConfig$1 as t };
|
|
15
|
-
//# sourceMappingURL=types-
|
|
15
|
+
//# sourceMappingURL=types-DsauAGkA.d.cts.map
|
package/dist/types.d.cts
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import { n as InitializeGTParams, r as TranslationsLoader, t as GTConfig } from "./types-
|
|
1
|
+
import { n as InitializeGTParams, r as TranslationsLoader, t as GTConfig } from "./types-DsauAGkA.cjs";
|
|
2
2
|
import { DictionaryTranslationOptions, GTFunctionType, InlineTranslationOptions, MFunctionType, RuntimeTranslationOptions, TFunctionType } from "gt-i18n/types";
|
|
3
3
|
export { type DictionaryTranslationOptions, GTConfig, type GTFunctionType, InitializeGTParams, type InlineTranslationOptions, type MFunctionType, type RuntimeTranslationOptions, type TFunctionType, TranslationsLoader };
|
package/dist/types.d.mts
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import { n as InitializeGTParams, r as TranslationsLoader, t as GTConfig } from "./types-
|
|
1
|
+
import { n as InitializeGTParams, r as TranslationsLoader, t as GTConfig } from "./types-D2TZTLXG.mjs";
|
|
2
2
|
import { DictionaryTranslationOptions, GTFunctionType, InlineTranslationOptions, MFunctionType, RuntimeTranslationOptions, TFunctionType } from "gt-i18n/types";
|
|
3
3
|
export { type DictionaryTranslationOptions, GTConfig, type GTFunctionType, InitializeGTParams, type InlineTranslationOptions, type MFunctionType, type RuntimeTranslationOptions, type TFunctionType, TranslationsLoader };
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "gt-node",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.7.0",
|
|
4
4
|
"description": "Node.js utilities for General Translation",
|
|
5
5
|
"main": "dist/index.cjs",
|
|
6
6
|
"module": "dist/index.mjs",
|
|
@@ -44,8 +44,8 @@
|
|
|
44
44
|
"definition": "dist/index.d.cts"
|
|
45
45
|
},
|
|
46
46
|
"dependencies": {
|
|
47
|
-
"gt-i18n": "0.
|
|
48
|
-
"generaltranslation": "8.2.
|
|
47
|
+
"gt-i18n": "0.9.0",
|
|
48
|
+
"generaltranslation": "8.2.12"
|
|
49
49
|
},
|
|
50
50
|
"exports": {
|
|
51
51
|
".": {
|
|
@@ -109,6 +109,7 @@
|
|
|
109
109
|
"release": "pnpm run build:clean && pnpm publish",
|
|
110
110
|
"release:alpha": "pnpm run build:clean && pnpm publish --tag alpha",
|
|
111
111
|
"release:beta": "pnpm run build:clean && pnpm publish --tag beta",
|
|
112
|
-
"release:latest": "pnpm run build:clean && pnpm publish --tag latest"
|
|
112
|
+
"release:latest": "pnpm run build:clean && pnpm publish --tag latest",
|
|
113
|
+
"typecheck": "tsc --noEmit"
|
|
113
114
|
}
|
|
114
115
|
}
|