Skip to content

Commit 02a7676

Browse files
committed
docs(readme): Improve docs
1 parent cc86ad7 commit 02a7676

File tree

2 files changed

+23
-1
lines changed

2 files changed

+23
-1
lines changed

README.md

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,9 @@
77
88
- [Installation](#installation)
99
- [Usage](#usage)
10+
- [Parameters](#parameters)
11+
- [Config file](#config-file)
12+
- [License](#license)
1013

1114
## Installation
1215

@@ -43,5 +46,24 @@ export function HttpLoaderFactory(translate: TranslateService, location: Locatio
4346
}
4447
```
4548

49+
### Config file
50+
51+
JSON config file has following structure:
52+
```
53+
{
54+
"locales": ["en", "de", ...],
55+
"prefix": "MY_PREFIX"
56+
}
57+
```
58+
59+
```ts
60+
interface ILocalizeRouterParserConfig {
61+
locales: Array<string>;
62+
prefix?: string;
63+
}
64+
```
65+
66+
Prefix field is not mandatory and default value is empty string.
67+
4668
## License
4769
Licensed under MIT

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "localize-router-http-loader",
3-
"version": "0.0.2",
3+
"version": "0.0.3",
44
"description": "A loader for localize-router that loads config using Http",
55
"scripts": {
66
"clean": "rimraf bundles coverage src/**/*.d.ts src/**/*.metadata.json src/**/*.js tests/**/*.d.ts tests/**/*.metadata.json tests/**/*.js index.d.ts index.metadata.json index.js",

0 commit comments

Comments
 (0)