@travetto/model-firestore 3.4.0-rc.7 → 3.4.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/README.md +2 -2
- package/package.json +5 -5
- package/src/config.ts +2 -2
package/README.md
CHANGED
|
@@ -39,7 +39,7 @@ where the [FirestoreModelConfig](https://github.com/travetto/travetto/tree/main/
|
|
|
39
39
|
|
|
40
40
|
**Code: Structure of FirestoreModelConfig**
|
|
41
41
|
```typescript
|
|
42
|
-
import {
|
|
42
|
+
import { ResourceLoader } from '@travetto/base';
|
|
43
43
|
import { Config } from '@travetto/config';
|
|
44
44
|
|
|
45
45
|
@Config('model.firestore')
|
|
@@ -62,7 +62,7 @@ export class FirestoreModelConfig {
|
|
|
62
62
|
process.env.FIRESTORE_EMULATOR_HOST = this.emulator;
|
|
63
63
|
}
|
|
64
64
|
if (this.credentialsFile && !this.credentials) {
|
|
65
|
-
const resources = new
|
|
65
|
+
const resources = new ResourceLoader();
|
|
66
66
|
this.credentials = JSON.parse(await resources.read(this.credentialsFile));
|
|
67
67
|
}
|
|
68
68
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@travetto/model-firestore",
|
|
3
|
-
"version": "3.4.0
|
|
3
|
+
"version": "3.4.0",
|
|
4
4
|
"description": "Firestore backing for the travetto model module.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"typescript",
|
|
@@ -26,12 +26,12 @@
|
|
|
26
26
|
},
|
|
27
27
|
"dependencies": {
|
|
28
28
|
"@google-cloud/firestore": "^7.1.0",
|
|
29
|
-
"@travetto/base": "^3.4.0
|
|
30
|
-
"@travetto/config": "^3.4.0
|
|
31
|
-
"@travetto/model": "^3.4.0
|
|
29
|
+
"@travetto/base": "^3.4.0",
|
|
30
|
+
"@travetto/config": "^3.4.0",
|
|
31
|
+
"@travetto/model": "^3.4.0"
|
|
32
32
|
},
|
|
33
33
|
"peerDependencies": {
|
|
34
|
-
"@travetto/command": "^3.4.0
|
|
34
|
+
"@travetto/command": "^3.4.0"
|
|
35
35
|
},
|
|
36
36
|
"peerDependenciesMeta": {
|
|
37
37
|
"@travetto/command": {
|
package/src/config.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { ResourceLoader } from '@travetto/base';
|
|
2
2
|
import { Config } from '@travetto/config';
|
|
3
3
|
|
|
4
4
|
@Config('model.firestore')
|
|
@@ -21,7 +21,7 @@ export class FirestoreModelConfig {
|
|
|
21
21
|
process.env.FIRESTORE_EMULATOR_HOST = this.emulator;
|
|
22
22
|
}
|
|
23
23
|
if (this.credentialsFile && !this.credentials) {
|
|
24
|
-
const resources = new
|
|
24
|
+
const resources = new ResourceLoader();
|
|
25
25
|
this.credentials = JSON.parse(await resources.read(this.credentialsFile));
|
|
26
26
|
}
|
|
27
27
|
}
|