@backstage/config-loader 1.4.0-next.1 → 1.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/CHANGELOG.md +68 -0
- package/package.json +3 -3
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,73 @@
|
|
|
1
1
|
# @backstage/config-loader
|
|
2
2
|
|
|
3
|
+
## 1.4.0
|
|
4
|
+
|
|
5
|
+
### Minor Changes
|
|
6
|
+
|
|
7
|
+
- 2f1859585998: Loading invalid TypeScript configuration schemas will now throw an error rather than silently being ignored.
|
|
8
|
+
|
|
9
|
+
In particular this includes defining any additional types other than `Config` in the schema file, or use of unsupported types such as `Record` or `Partial`.
|
|
10
|
+
|
|
11
|
+
- cd514545d1d0: Adds a new `deepVisibility` schema keyword that sets child visibility recursively to the defined value, respecting preexisting values or child `deepVisibility`.
|
|
12
|
+
|
|
13
|
+
Example usage:
|
|
14
|
+
|
|
15
|
+
```ts
|
|
16
|
+
export interface Config {
|
|
17
|
+
/**
|
|
18
|
+
* Enforces a default of `secret` instead of `backend` for this object.
|
|
19
|
+
* @deepVisibility secret
|
|
20
|
+
*/
|
|
21
|
+
mySecretProperty: {
|
|
22
|
+
type: 'object';
|
|
23
|
+
properties: {
|
|
24
|
+
secretValue: {
|
|
25
|
+
type: 'string';
|
|
26
|
+
};
|
|
27
|
+
|
|
28
|
+
verySecretProperty: {
|
|
29
|
+
type: 'string';
|
|
30
|
+
};
|
|
31
|
+
};
|
|
32
|
+
};
|
|
33
|
+
}
|
|
34
|
+
```
|
|
35
|
+
|
|
36
|
+
Example of a schema that would not be allowed:
|
|
37
|
+
|
|
38
|
+
```ts
|
|
39
|
+
export interface Config {
|
|
40
|
+
/**
|
|
41
|
+
* Set the top level property to secret, enforcing a default of `secret` instead of `backend` for this object.
|
|
42
|
+
* @deepVisibility secret
|
|
43
|
+
*/
|
|
44
|
+
mySecretProperty: {
|
|
45
|
+
type: 'object';
|
|
46
|
+
properties: {
|
|
47
|
+
frontendUrl: {
|
|
48
|
+
/**
|
|
49
|
+
* We can NOT override the visibility to reveal a property to the front end.
|
|
50
|
+
* @visibility frontend
|
|
51
|
+
*/
|
|
52
|
+
type: 'string';
|
|
53
|
+
};
|
|
54
|
+
|
|
55
|
+
verySecretProperty: {
|
|
56
|
+
type: 'string';
|
|
57
|
+
};
|
|
58
|
+
};
|
|
59
|
+
};
|
|
60
|
+
}
|
|
61
|
+
```
|
|
62
|
+
|
|
63
|
+
### Patch Changes
|
|
64
|
+
|
|
65
|
+
- Updated dependencies
|
|
66
|
+
- @backstage/cli-common@0.1.12
|
|
67
|
+
- @backstage/config@1.0.8
|
|
68
|
+
- @backstage/errors@1.2.1
|
|
69
|
+
- @backstage/types@1.1.0
|
|
70
|
+
|
|
3
71
|
## 1.4.0-next.1
|
|
4
72
|
|
|
5
73
|
### Minor Changes
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@backstage/config-loader",
|
|
3
3
|
"description": "Config loading functionality used by Backstage backend, and CLI",
|
|
4
|
-
"version": "1.4.0
|
|
4
|
+
"version": "1.4.0",
|
|
5
5
|
"publishConfig": {
|
|
6
6
|
"access": "public",
|
|
7
7
|
"main": "dist/index.cjs.js",
|
|
@@ -52,8 +52,8 @@
|
|
|
52
52
|
"yup": "^0.32.9"
|
|
53
53
|
},
|
|
54
54
|
"devDependencies": {
|
|
55
|
-
"@backstage/backend-test-utils": "^0.2.0
|
|
56
|
-
"@backstage/cli": "^0.22.10
|
|
55
|
+
"@backstage/backend-test-utils": "^0.2.0",
|
|
56
|
+
"@backstage/cli": "^0.22.10",
|
|
57
57
|
"@types/json-schema-merge-allof": "^0.6.0",
|
|
58
58
|
"@types/mock-fs": "^4.10.0",
|
|
59
59
|
"@types/node": "^16.11.26",
|