@ogs-gmbh/ngx-translate 1.4.0 → 2.0.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/LICENSE +1 -1
- package/README.md +105 -50
- package/fesm2022/ogs-gmbh-ngx-translate.mjs +368 -220
- package/fesm2022/ogs-gmbh-ngx-translate.mjs.map +1 -1
- package/package.json +9 -13
- package/types/ogs-gmbh-ngx-translate.d.ts +1188 -0
- package/enums/collecting-strategies.enum.d.ts +0 -23
- package/enums/preloading-strategies.enum.d.ts +0 -23
- package/errors/locale-not-defined.error.d.ts +0 -5
- package/errors/scope-not-defined.error.d.ts +0 -4
- package/errors/source-locale-not-defined.error.d.ts +0 -4
- package/errors/translation-not-defined.error.d.ts +0 -4
- package/esm2022/enums/collecting-strategies.enum.mjs +0 -25
- package/esm2022/enums/preloading-strategies.enum.mjs +0 -25
- package/esm2022/errors/locale-not-defined.error.mjs +0 -8
- package/esm2022/errors/scope-not-defined.error.mjs +0 -10
- package/esm2022/errors/source-locale-not-defined.error.mjs +0 -8
- package/esm2022/errors/translation-not-defined.error.mjs +0 -8
- package/esm2022/interceptors/translation.interceptor.mjs +0 -31
- package/esm2022/lib.module.mjs +0 -68
- package/esm2022/ogs-gmbh-ngx-translate.mjs +0 -5
- package/esm2022/pipe.module.mjs +0 -31
- package/esm2022/pipes/translation.pipe.mjs +0 -70
- package/esm2022/providers/config.provider.mjs +0 -16
- package/esm2022/providers/http.provider.mjs +0 -32
- package/esm2022/providers/interceptor.provider.mjs +0 -16
- package/esm2022/providers/preload.provider.mjs +0 -84
- package/esm2022/providers/scope.provider.mjs +0 -16
- package/esm2022/public-api.mjs +0 -23
- package/esm2022/services/translation-http.serivce.mjs +0 -58
- package/esm2022/services/translation-store.service.mjs +0 -379
- package/esm2022/services/translation.service.mjs +0 -332
- package/esm2022/tokens/config.token.mjs +0 -10
- package/esm2022/tokens/http.token.mjs +0 -18
- package/esm2022/tokens/preload.token.mjs +0 -10
- package/esm2022/tokens/scope.token.mjs +0 -10
- package/esm2022/types/config.type.mjs +0 -2
- package/esm2022/types/provider.type.mjs +0 -2
- package/esm2022/types/store.type.mjs +0 -2
- package/esm2022/utils/file.util.mjs +0 -85
- package/esm2022/utils/translate.util.mjs +0 -39
- package/index.d.ts +0 -5
- package/interceptors/translation.interceptor.d.ts +0 -16
- package/lib.module.d.ts +0 -24
- package/pipe.module.d.ts +0 -14
- package/pipes/translation.pipe.d.ts +0 -67
- package/providers/config.provider.d.ts +0 -12
- package/providers/http.provider.d.ts +0 -23
- package/providers/interceptor.provider.d.ts +0 -10
- package/providers/preload.provider.d.ts +0 -22
- package/providers/scope.provider.d.ts +0 -11
- package/public-api.d.ts +0 -22
- package/services/translation-http.serivce.d.ts +0 -23
- package/services/translation-store.service.d.ts +0 -214
- package/services/translation.service.d.ts +0 -108
- package/tokens/config.token.d.ts +0 -10
- package/tokens/http.token.d.ts +0 -18
- package/tokens/preload.token.d.ts +0 -9
- package/tokens/scope.token.d.ts +0 -9
- package/types/config.type.d.ts +0 -194
- package/types/provider.type.d.ts +0 -44
- package/types/store.type.d.ts +0 -113
- package/utils/file.util.d.ts +0 -24
- package/utils/translate.util.d.ts +0 -19
package/LICENSE
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
MIT License
|
|
2
2
|
|
|
3
|
-
Copyright (c) 2025 OGS Gesellschaft für Datenverarbeitung und Systemberatung mbH
|
|
3
|
+
Copyright (c) 2025 — present OGS Gesellschaft für Datenverarbeitung und Systemberatung mbH
|
|
4
4
|
|
|
5
5
|
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
6
|
of this software and associated documentation files (the "Software"), to deal
|
package/README.md
CHANGED
|
@@ -1,50 +1,105 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
*
|
|
2
|
+
|
|
3
|
+
# ngx-translate
|
|
4
|
+
|
|
5
|
+

|
|
6
|
+
|
|
7
|
+
<a href="./LICENSE" target="_blank"><img src="https://img.shields.io/github/license/OGS-GmbH/ngx-translate?color=0f434e&logo=hackthebox&logoColor=000000&labelColor=ffffff" /></a>
|
|
8
|
+
<a href="https://github.com/OGS-GmbH/ngx-translate/actions/workflows/main-deploy.yml" target="_blank"><img src="https://img.shields.io/github/actions/workflow/status/OGS-GmbH/ngx-translate/main-deploy.yml?color=0f434e&logo=rocket&logoColor=000000&labelColor=ffffff" /></a>
|
|
9
|
+
<a href="https://www.npmjs.com/package/@ogs-gmbh/ngx-translate" target="_blank"><img src="https://img.shields.io/npm/v/%40ogs-gmbh%2Fngx-translate?color=0f434e&logo=npm&logoColor=000000&labelColor=ffffff" /></a>
|
|
10
|
+
|
|
11
|
+
- **REST-based**\
|
|
12
|
+
Save, query and provide translations by API.
|
|
13
|
+
|
|
14
|
+
- **Optimized for performance**\
|
|
15
|
+
Pre-load, lazy-load and cache your translations
|
|
16
|
+
|
|
17
|
+
- **Multi-scoping ready**
|
|
18
|
+
Request multiple scopes which include translations at once
|
|
19
|
+
|
|
20
|
+
- **Developer experience**\
|
|
21
|
+
Use a local language for development & production
|
|
22
|
+
|
|
23
|
+
## Getting Started
|
|
24
|
+
|
|
25
|
+
> [!IMPORTANT]
|
|
26
|
+
> We're offering an extensive API-Reference covered with in-depth usage examples of this project.
|
|
27
|
+
|
|
28
|
+
To get a starting point, simply refer to our documentation at [ogs-gmbh.github.io/ngx-translate](https://ogs-gmbh.github.io/ngx-translate).
|
|
29
|
+
|
|
30
|
+
## Prerequisites
|
|
31
|
+
|
|
32
|
+
- Node.js version 18 or higher
|
|
33
|
+
- A package manager: e.g. npm, pnpm, ...
|
|
34
|
+
|
|
35
|
+
## Installation
|
|
36
|
+
|
|
37
|
+
Using npm:
|
|
38
|
+
```sh
|
|
39
|
+
$ npm install @ogs-gmbh/ngx-translate
|
|
40
|
+
```
|
|
41
|
+
|
|
42
|
+
<details>
|
|
43
|
+
<summary>Using a different package managers?</summary>
|
|
44
|
+
<br/>
|
|
45
|
+
|
|
46
|
+
Using yarn:
|
|
47
|
+
```sh
|
|
48
|
+
$ pnpm add @ogs-gmbh/ngx-translate
|
|
49
|
+
```
|
|
50
|
+
|
|
51
|
+
Using pnpm:
|
|
52
|
+
```sh
|
|
53
|
+
$ pnpm add @ogs-gmbh/ngx-translate
|
|
54
|
+
```
|
|
55
|
+
|
|
56
|
+
Using bun:
|
|
57
|
+
```sh
|
|
58
|
+
$ bun add @ogs-gmbh/ngx-translate
|
|
59
|
+
```
|
|
60
|
+
|
|
61
|
+
</details>
|
|
62
|
+
|
|
63
|
+
## License
|
|
64
|
+
|
|
65
|
+
The MIT License (MIT) - Please have a look at the [LICENSE file](./LICENSE) for more details.
|
|
66
|
+
|
|
67
|
+
## Contributing
|
|
68
|
+
Contributions are always welcome and greatly appreciated. Whether you want to report a bug, suggest a new feature, or improve the documentation, your input helps make the project better for everyone.
|
|
69
|
+
|
|
70
|
+
Feel free to submit a pull request, issue or feature request.
|
|
71
|
+
|
|
72
|
+
### Issues and Feature Requests
|
|
73
|
+
Reporting an issue or creating a feature request is made by creating a new issue on this repository.
|
|
74
|
+
|
|
75
|
+
You can create a [new issue or feature request here](../../issues/new/choose).
|
|
76
|
+
|
|
77
|
+
### Pull Requests
|
|
78
|
+
GitHub offers a solid guideline for contributing to open source projects through pull requests, covering key practices. These best practices provide a reliable starting point for making effective contributions.
|
|
79
|
+
|
|
80
|
+
You can find the [guidelines here](https://docs.github.com/get-started/exploring-projects-on-github/contributing-to-a-project).
|
|
81
|
+
|
|
82
|
+
### Code Of Conduct
|
|
83
|
+
We are committed to keeping a welcoming, inclusive, and respectful community for everyone. To help us achieve this, we kindly ask that you adhere to our [Code of Conduct](./CODE_OF_CONDUCT.md).
|
|
84
|
+
|
|
85
|
+
## Disclaimer
|
|
86
|
+
|
|
87
|
+
All trademarks and registered trademarks mentioned are property of their respective owners and are used for identification purposes only. Use of these names does not imply endorsement or affiliation.
|
|
88
|
+
|
|
89
|
+
This project is a trademark of OGS Gesellschaft für Datenverarbeitung und Systemberatung mbH. The License does not grant rights to use the trademark without permission.
|
|
90
|
+
|
|
91
|
+
---
|
|
92
|
+
|
|
93
|
+
<a href="https://www.ogs.de/en/">
|
|
94
|
+
<picture>
|
|
95
|
+
<source
|
|
96
|
+
srcset="https://raw.githubusercontent.com/OGS-GmbH/.github/refs/tags/v1.0.0/docs/assets/logo/light.svg"
|
|
97
|
+
media="(prefers-color-scheme: dark)"
|
|
98
|
+
/>
|
|
99
|
+
<img height="64" alt="OGS Logo" src="https://raw.githubusercontent.com/OGS-GmbH/.github/refs/tags/v1.0.0/docs/assets/logo/dark.svg"
|
|
100
|
+
</picture>
|
|
101
|
+
</a>
|
|
102
|
+
|
|
103
|
+
Gesellschaft für Datenverarbeitung und Systemberatung mbH
|
|
104
|
+
|
|
105
|
+
[Imprint](https://www.ogs.de/en/imprint/) | [Contact](https://www.ogs.de/en/contact/) | [Careers](https://www.ogs.de/en/about-ogs/#Careers)
|