@twin.org/core 0.9.2-next.3 → 0.9.2-next.5
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/dist/es/index.js +0 -2
- package/dist/es/index.js.map +1 -1
- package/dist/es/models/IComponent.js +2 -0
- package/dist/es/models/IComponent.js.map +1 -1
- package/dist/types/index.d.ts +0 -2
- package/dist/types/models/IComponent.d.ts +0 -6
- package/docs/changelog.md +34 -0
- package/docs/reference/index.md +0 -3
- package/docs/reference/interfaces/IComponent.md +0 -14
- package/package.json +2 -2
- package/dist/es/models/IHealth.js +0 -2
- package/dist/es/models/IHealth.js.map +0 -1
- package/dist/es/models/healthStatus.js +0 -21
- package/dist/es/models/healthStatus.js.map +0 -1
- package/dist/types/models/IHealth.d.ts +0 -32
- package/dist/types/models/healthStatus.d.ts +0 -21
- package/docs/reference/interfaces/IHealth.md +0 -55
- package/docs/reference/type-aliases/HealthStatus.md +0 -5
- package/docs/reference/variables/HealthStatus.md +0 -25
package/dist/es/index.js
CHANGED
|
@@ -31,10 +31,8 @@ export * from "./helpers/uint8ArrayHelper.js";
|
|
|
31
31
|
export * from "./models/coerceType.js";
|
|
32
32
|
export * from "./models/IDuration.js";
|
|
33
33
|
export * from "./models/compressionType.js";
|
|
34
|
-
export * from "./models/healthStatus.js";
|
|
35
34
|
export * from "./models/IComponent.js";
|
|
36
35
|
export * from "./models/IError.js";
|
|
37
|
-
export * from "./models/IHealth.js";
|
|
38
36
|
export * from "./models/II18nShared.js";
|
|
39
37
|
export * from "./models/IKeyValue.js";
|
|
40
38
|
export * from "./models/ILabelledValue.js";
|
package/dist/es/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":"AAAA,gCAAgC;AAChC,uCAAuC;AACvC,cAAc,sBAAsB,CAAC;AACrC,cAAc,sBAAsB,CAAC;AACrC,cAAc,sBAAsB,CAAC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AACrC,cAAc,mBAAmB,CAAC;AAClC,cAAc,iBAAiB,CAAC;AAChC,cAAc,eAAe,CAAC;AAC9B,cAAc,kBAAkB,CAAC;AACjC,cAAc,+BAA+B,CAAC;AAC9C,cAAc,wBAAwB,CAAC;AACvC,cAAc,uBAAuB,CAAC","sourcesContent":["// Copyright 2024 IOTA Stiftung.\n// SPDX-License-Identifier: Apache-2.0.\nexport * from \"./encoding/base32.js\";\nexport * from \"./encoding/base58.js\";\nexport * from \"./encoding/base64.js\";\nexport * from \"./encoding/base64Url.js\";\nexport * from \"./errors/alreadyExistsError.js\";\nexport * from \"./errors/baseError.js\";\nexport * from \"./errors/conflictError.js\";\nexport * from \"./errors/generalError.js\";\nexport * from \"./errors/guardError.js\";\nexport * from \"./errors/notFoundError.js\";\nexport * from \"./errors/notImplementedError.js\";\nexport * from \"./errors/notSupportedError.js\";\nexport * from \"./errors/unauthorizedError.js\";\nexport * from \"./errors/unprocessableError.js\";\nexport * from \"./errors/validationError.js\";\nexport * from \"./factories/componentFactory.js\";\nexport * from \"./factories/factory.js\";\nexport * from \"./helpers/arrayHelper.js\";\nexport * from \"./helpers/envHelper.js\";\nexport * from \"./helpers/errorHelper.js\";\nexport * from \"./helpers/filenameHelper.js\";\nexport * from \"./helpers/hexHelper.js\";\nexport * from \"./helpers/jsonHelper.js\";\nexport * from \"./helpers/numberHelper.js\";\nexport * from \"./helpers/objectHelper.js\";\nexport * from \"./helpers/randomHelper.js\";\nexport * from \"./helpers/stringHelper.js\";\nexport * from \"./helpers/uint8ArrayHelper.js\";\nexport * from \"./models/coerceType.js\";\nexport * from \"./models/IDuration.js\";\nexport * from \"./models/compressionType.js\";\nexport * from \"./models/IComponent.js\";\nexport * from \"./models/IError.js\";\nexport * from \"./models/II18nShared.js\";\nexport * from \"./models/IKeyValue.js\";\nexport * from \"./models/ILabelledValue.js\";\nexport * from \"./models/ILocale.js\";\nexport * from \"./models/ILocaleDictionary.js\";\nexport * from \"./models/ILocalesIndex.js\";\nexport * from \"./models/IMutexWorkerMessage.js\";\nexport * from \"./models/IPatchOperation.js\";\nexport * from \"./models/ISharedObjectBufferOptions.js\";\nexport * from \"./models/ISharedObjectBufferWorkerMessage.js\";\nexport * from \"./models/IUrlParts.js\";\nexport * from \"./models/IValidationFailure.js\";\nexport * from \"./models/mutexMessageTypes.js\";\nexport * from \"./models/sharedObjectBufferMessageTypes.js\";\nexport * from \"./types/bitString.js\";\nexport * from \"./types/duration.js\";\nexport * from \"./types/durationRegExp.js\";\nexport * from \"./types/objectOrArray.js\";\nexport * from \"./types/singleOccurrenceArray.js\";\nexport * from \"./types/singleOccurrenceArrayDepthHelper.js\";\nexport * from \"./types/url.js\";\nexport * from \"./types/urn.js\";\nexport * from \"./utils/asyncCache.js\";\nexport * from \"./utils/coerce.js\";\nexport * from \"./utils/compression.js\";\nexport * from \"./utils/converter.js\";\nexport * from \"./utils/guards.js\";\nexport * from \"./utils/i18n.js\";\nexport * from \"./utils/is.js\";\nexport * from \"./utils/mutex.js\";\nexport * from \"./utils/sharedObjectBuffer.js\";\nexport * from \"./utils/sharedStore.js\";\nexport * from \"./utils/validation.js\";\n"]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"IComponent.js","sourceRoot":"","sources":["../../../src/models/IComponent.ts"],"names":[],"mappings":"","sourcesContent":["// Copyright 2024 IOTA Stiftung.\n// SPDX-License-Identifier: Apache-2.0.\
|
|
1
|
+
{"version":3,"file":"IComponent.js","sourceRoot":"","sources":["../../../src/models/IComponent.ts"],"names":[],"mappings":"AAAA,gCAAgC;AAChC,uCAAuC","sourcesContent":["// Copyright 2024 IOTA Stiftung.\n// SPDX-License-Identifier: Apache-2.0.\n\n/**\n * Interface describing a component which can be bootstrapped, started and stopped.\n */\nexport interface IComponent {\n\t/**\n\t * Returns the class name of the component.\n\t * @returns The class name of the component.\n\t */\n\tclassName(): string;\n\n\t/**\n\t * Bootstrap the component by creating and initializing any resources it needs.\n\t * @param nodeLoggingComponentType The node logging component type.\n\t * @returns True if the bootstrapping process was successful.\n\t */\n\tbootstrap?(nodeLoggingComponentType?: string): Promise<boolean>;\n\n\t/**\n\t * Teardown the component by releasing any resources it holds.\n\t * @param nodeLoggingComponentType The node logging component type.\n\t * @returns True if the teardown process was successful.\n\t */\n\tteardown?(nodeLoggingComponentType?: string): Promise<boolean>;\n\n\t/**\n\t * The component needs to be started when the node is initialized.\n\t * @param nodeLoggingComponentType The node logging component type.\n\t * @returns A promise that resolves when the component has started.\n\t */\n\tstart?(nodeLoggingComponentType?: string): Promise<void>;\n\n\t/**\n\t * The component needs to be stopped when the node is closed.\n\t * @param nodeLoggingComponentType The node logging component type.\n\t * @returns A promise that resolves when the component has stopped.\n\t */\n\tstop?(nodeLoggingComponentType?: string): Promise<void>;\n}\n"]}
|
package/dist/types/index.d.ts
CHANGED
|
@@ -29,10 +29,8 @@ export * from "./helpers/uint8ArrayHelper.js";
|
|
|
29
29
|
export * from "./models/coerceType.js";
|
|
30
30
|
export * from "./models/IDuration.js";
|
|
31
31
|
export * from "./models/compressionType.js";
|
|
32
|
-
export * from "./models/healthStatus.js";
|
|
33
32
|
export * from "./models/IComponent.js";
|
|
34
33
|
export * from "./models/IError.js";
|
|
35
|
-
export * from "./models/IHealth.js";
|
|
36
34
|
export * from "./models/II18nShared.js";
|
|
37
35
|
export * from "./models/IKeyValue.js";
|
|
38
36
|
export * from "./models/ILabelledValue.js";
|
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
import type { IHealth } from "./IHealth.js";
|
|
2
1
|
/**
|
|
3
2
|
* Interface describing a component which can be bootstrapped, started and stopped.
|
|
4
3
|
*/
|
|
@@ -32,9 +31,4 @@ export interface IComponent {
|
|
|
32
31
|
* @returns A promise that resolves when the component has stopped.
|
|
33
32
|
*/
|
|
34
33
|
stop?(nodeLoggingComponentType?: string): Promise<void>;
|
|
35
|
-
/**
|
|
36
|
-
* Returns the health status of the component.
|
|
37
|
-
* @returns The health status of the component, can return multiple entries for elements within the component.
|
|
38
|
-
*/
|
|
39
|
-
health?(): Promise<IHealth[]>;
|
|
40
34
|
}
|
package/docs/changelog.md
CHANGED
|
@@ -1,5 +1,39 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
+
## [0.9.2-next.5](https://github.com/iotaledger/twin-framework/compare/core-v0.9.2-next.4...core-v0.9.2-next.5) (2026-08-03)
|
|
4
|
+
|
|
5
|
+
|
|
6
|
+
### Features
|
|
7
|
+
|
|
8
|
+
* move health support to api repo ([#435](https://github.com/iotaledger/twin-framework/issues/435)) ([867f766](https://github.com/iotaledger/twin-framework/commit/867f766afc86607bec6b5cf9c3ab5bd5c41d0b3c))
|
|
9
|
+
|
|
10
|
+
|
|
11
|
+
### Dependencies
|
|
12
|
+
|
|
13
|
+
* The following workspace dependencies were updated
|
|
14
|
+
* dependencies
|
|
15
|
+
* @twin.org/nameof bumped from 0.9.2-next.4 to 0.9.2-next.5
|
|
16
|
+
* devDependencies
|
|
17
|
+
* @twin.org/nameof-transformer bumped from 0.9.2-next.4 to 0.9.2-next.5
|
|
18
|
+
* @twin.org/nameof-vitest-plugin bumped from 0.9.2-next.4 to 0.9.2-next.5
|
|
19
|
+
|
|
20
|
+
## [0.9.2-next.4](https://github.com/iotaledger/twin-framework/compare/core-v0.9.2-next.3...core-v0.9.2-next.4) (2026-07-31)
|
|
21
|
+
|
|
22
|
+
|
|
23
|
+
### Miscellaneous Chores
|
|
24
|
+
|
|
25
|
+
* **core:** Synchronize repo versions
|
|
26
|
+
|
|
27
|
+
|
|
28
|
+
### Dependencies
|
|
29
|
+
|
|
30
|
+
* The following workspace dependencies were updated
|
|
31
|
+
* dependencies
|
|
32
|
+
* @twin.org/nameof bumped from 0.9.2-next.3 to 0.9.2-next.4
|
|
33
|
+
* devDependencies
|
|
34
|
+
* @twin.org/nameof-transformer bumped from 0.9.2-next.3 to 0.9.2-next.4
|
|
35
|
+
* @twin.org/nameof-vitest-plugin bumped from 0.9.2-next.3 to 0.9.2-next.4
|
|
36
|
+
|
|
3
37
|
## [0.9.2-next.3](https://github.com/iotaledger/twin-framework/compare/core-v0.9.2-next.2...core-v0.9.2-next.3) (2026-07-30)
|
|
4
38
|
|
|
5
39
|
|
package/docs/reference/index.md
CHANGED
|
@@ -50,7 +50,6 @@
|
|
|
50
50
|
- [IComponent](interfaces/IComponent.md)
|
|
51
51
|
- [IDuration](interfaces/IDuration.md)
|
|
52
52
|
- [IError](interfaces/IError.md)
|
|
53
|
-
- [IHealth](interfaces/IHealth.md)
|
|
54
53
|
- [II18nShared](interfaces/II18nShared.md)
|
|
55
54
|
- [IKeyValue](interfaces/IKeyValue.md)
|
|
56
55
|
- [ILabelledValue](interfaces/ILabelledValue.md)
|
|
@@ -68,7 +67,6 @@
|
|
|
68
67
|
|
|
69
68
|
- [CoerceType](type-aliases/CoerceType.md)
|
|
70
69
|
- [CompressionType](type-aliases/CompressionType.md)
|
|
71
|
-
- [HealthStatus](type-aliases/HealthStatus.md)
|
|
72
70
|
- [MutexMessageTypes](type-aliases/MutexMessageTypes.md)
|
|
73
71
|
- [SharedObjectBufferMessageTypes](type-aliases/SharedObjectBufferMessageTypes.md)
|
|
74
72
|
- [ObjectOrArray](type-aliases/ObjectOrArray.md)
|
|
@@ -80,7 +78,6 @@
|
|
|
80
78
|
- [ComponentFactory](variables/ComponentFactory.md)
|
|
81
79
|
- [CoerceType](variables/CoerceType.md)
|
|
82
80
|
- [CompressionType](variables/CompressionType.md)
|
|
83
|
-
- [HealthStatus](variables/HealthStatus.md)
|
|
84
81
|
- [MutexMessageTypes](variables/MutexMessageTypes.md)
|
|
85
82
|
- [SharedObjectBufferMessageTypes](variables/SharedObjectBufferMessageTypes.md)
|
|
86
83
|
- [DURATION\_REG\_EXP](variables/DURATION_REG_EXP.md)
|
|
@@ -103,17 +103,3 @@ The node logging component type.
|
|
|
103
103
|
`Promise`\<`void`\>
|
|
104
104
|
|
|
105
105
|
A promise that resolves when the component has stopped.
|
|
106
|
-
|
|
107
|
-
***
|
|
108
|
-
|
|
109
|
-
### health()? {#health}
|
|
110
|
-
|
|
111
|
-
> `optional` **health**(): `Promise`\<[`IHealth`](IHealth.md)[]\>
|
|
112
|
-
|
|
113
|
-
Returns the health status of the component.
|
|
114
|
-
|
|
115
|
-
#### Returns
|
|
116
|
-
|
|
117
|
-
`Promise`\<[`IHealth`](IHealth.md)[]\>
|
|
118
|
-
|
|
119
|
-
The health status of the component, can return multiple entries for elements within the component.
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@twin.org/core",
|
|
3
|
-
"version": "0.9.2-next.
|
|
3
|
+
"version": "0.9.2-next.5",
|
|
4
4
|
"description": "Helper methods/classes for data type checking/validation/guarding/error handling",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|
|
@@ -14,7 +14,7 @@
|
|
|
14
14
|
"node": ">=24.0.0"
|
|
15
15
|
},
|
|
16
16
|
"dependencies": {
|
|
17
|
-
"@twin.org/nameof": "0.9.2-next.
|
|
17
|
+
"@twin.org/nameof": "0.9.2-next.5",
|
|
18
18
|
"intl-messageformat": "11.2.12",
|
|
19
19
|
"rfc6902": "5.2.0"
|
|
20
20
|
},
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"IHealth.js","sourceRoot":"","sources":["../../../src/models/IHealth.ts"],"names":[],"mappings":"","sourcesContent":["// Copyright 2026 IOTA Stiftung.\n// SPDX-License-Identifier: Apache-2.0.\nimport type { HealthStatus } from \"./healthStatus.js\";\n\n/**\n * Provides health information for a component.\n */\nexport interface IHealth {\n\t/**\n\t * The source of the health information.\n\t */\n\tsource: string;\n\n\t/**\n\t * The description of the component as an i18n key.\n\t */\n\tdescription?: string;\n\n\t/**\n\t * The overall status of the component, the entries can also report their own health.\n\t */\n\tstatus: HealthStatus;\n\n\t/**\n\t * The message for the status if there are further details to provide as an i18n key.\n\t */\n\tmessage?: string;\n\n\t/**\n\t * Data to substitute in the i18n key for the message.\n\t */\n\tdata?: { [id: string]: unknown };\n\n\t/**\n\t * The grouped child components, if any.\n\t */\n\tgrouped?: IHealth[];\n}\n"]}
|
|
@@ -1,21 +0,0 @@
|
|
|
1
|
-
// Copyright 2024 IOTA Stiftung.
|
|
2
|
-
// SPDX-License-Identifier: Apache-2.0.
|
|
3
|
-
/**
|
|
4
|
-
* The health status of the component.
|
|
5
|
-
*/
|
|
6
|
-
// eslint-disable-next-line @typescript-eslint/naming-convention
|
|
7
|
-
export const HealthStatus = {
|
|
8
|
-
/**
|
|
9
|
-
* OK.
|
|
10
|
-
*/
|
|
11
|
-
Ok: "ok",
|
|
12
|
-
/**
|
|
13
|
-
* Warning.
|
|
14
|
-
*/
|
|
15
|
-
Warning: "warning",
|
|
16
|
-
/**
|
|
17
|
-
* Error.
|
|
18
|
-
*/
|
|
19
|
-
Error: "error"
|
|
20
|
-
};
|
|
21
|
-
//# sourceMappingURL=healthStatus.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"healthStatus.js","sourceRoot":"","sources":["../../../src/models/healthStatus.ts"],"names":[],"mappings":"AAAA,gCAAgC;AAChC,uCAAuC;AAEvC;;GAEG;AACH,gEAAgE;AAChE,MAAM,CAAC,MAAM,YAAY,GAAG;IAC3B;;OAEG;IACH,EAAE,EAAE,IAAI;IAER;;OAEG;IACH,OAAO,EAAE,SAAS;IAElB;;OAEG;IACH,KAAK,EAAE,OAAO;CACL,CAAC","sourcesContent":["// Copyright 2024 IOTA Stiftung.\n// SPDX-License-Identifier: Apache-2.0.\n\n/**\n * The health status of the component.\n */\n// eslint-disable-next-line @typescript-eslint/naming-convention\nexport const HealthStatus = {\n\t/**\n\t * OK.\n\t */\n\tOk: \"ok\",\n\n\t/**\n\t * Warning.\n\t */\n\tWarning: \"warning\",\n\n\t/**\n\t * Error.\n\t */\n\tError: \"error\"\n} as const;\n\n/**\n * The health status of the component.\n */\nexport type HealthStatus = (typeof HealthStatus)[keyof typeof HealthStatus];\n"]}
|
|
@@ -1,32 +0,0 @@
|
|
|
1
|
-
import type { HealthStatus } from "./healthStatus.js";
|
|
2
|
-
/**
|
|
3
|
-
* Provides health information for a component.
|
|
4
|
-
*/
|
|
5
|
-
export interface IHealth {
|
|
6
|
-
/**
|
|
7
|
-
* The source of the health information.
|
|
8
|
-
*/
|
|
9
|
-
source: string;
|
|
10
|
-
/**
|
|
11
|
-
* The description of the component as an i18n key.
|
|
12
|
-
*/
|
|
13
|
-
description?: string;
|
|
14
|
-
/**
|
|
15
|
-
* The overall status of the component, the entries can also report their own health.
|
|
16
|
-
*/
|
|
17
|
-
status: HealthStatus;
|
|
18
|
-
/**
|
|
19
|
-
* The message for the status if there are further details to provide as an i18n key.
|
|
20
|
-
*/
|
|
21
|
-
message?: string;
|
|
22
|
-
/**
|
|
23
|
-
* Data to substitute in the i18n key for the message.
|
|
24
|
-
*/
|
|
25
|
-
data?: {
|
|
26
|
-
[id: string]: unknown;
|
|
27
|
-
};
|
|
28
|
-
/**
|
|
29
|
-
* The grouped child components, if any.
|
|
30
|
-
*/
|
|
31
|
-
grouped?: IHealth[];
|
|
32
|
-
}
|
|
@@ -1,21 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* The health status of the component.
|
|
3
|
-
*/
|
|
4
|
-
export declare const HealthStatus: {
|
|
5
|
-
/**
|
|
6
|
-
* OK.
|
|
7
|
-
*/
|
|
8
|
-
readonly Ok: "ok";
|
|
9
|
-
/**
|
|
10
|
-
* Warning.
|
|
11
|
-
*/
|
|
12
|
-
readonly Warning: "warning";
|
|
13
|
-
/**
|
|
14
|
-
* Error.
|
|
15
|
-
*/
|
|
16
|
-
readonly Error: "error";
|
|
17
|
-
};
|
|
18
|
-
/**
|
|
19
|
-
* The health status of the component.
|
|
20
|
-
*/
|
|
21
|
-
export type HealthStatus = (typeof HealthStatus)[keyof typeof HealthStatus];
|
|
@@ -1,55 +0,0 @@
|
|
|
1
|
-
# Interface: IHealth
|
|
2
|
-
|
|
3
|
-
Provides health information for a component.
|
|
4
|
-
|
|
5
|
-
## Properties
|
|
6
|
-
|
|
7
|
-
### source {#source}
|
|
8
|
-
|
|
9
|
-
> **source**: `string`
|
|
10
|
-
|
|
11
|
-
The source of the health information.
|
|
12
|
-
|
|
13
|
-
***
|
|
14
|
-
|
|
15
|
-
### description? {#description}
|
|
16
|
-
|
|
17
|
-
> `optional` **description?**: `string`
|
|
18
|
-
|
|
19
|
-
The description of the component as an i18n key.
|
|
20
|
-
|
|
21
|
-
***
|
|
22
|
-
|
|
23
|
-
### status {#status}
|
|
24
|
-
|
|
25
|
-
> **status**: [`HealthStatus`](../type-aliases/HealthStatus.md)
|
|
26
|
-
|
|
27
|
-
The overall status of the component, the entries can also report their own health.
|
|
28
|
-
|
|
29
|
-
***
|
|
30
|
-
|
|
31
|
-
### message? {#message}
|
|
32
|
-
|
|
33
|
-
> `optional` **message?**: `string`
|
|
34
|
-
|
|
35
|
-
The message for the status if there are further details to provide as an i18n key.
|
|
36
|
-
|
|
37
|
-
***
|
|
38
|
-
|
|
39
|
-
### data? {#data}
|
|
40
|
-
|
|
41
|
-
> `optional` **data?**: `object`
|
|
42
|
-
|
|
43
|
-
Data to substitute in the i18n key for the message.
|
|
44
|
-
|
|
45
|
-
#### Index Signature
|
|
46
|
-
|
|
47
|
-
\[`id`: `string`\]: `unknown`
|
|
48
|
-
|
|
49
|
-
***
|
|
50
|
-
|
|
51
|
-
### grouped? {#grouped}
|
|
52
|
-
|
|
53
|
-
> `optional` **grouped?**: `IHealth`[]
|
|
54
|
-
|
|
55
|
-
The grouped child components, if any.
|
|
@@ -1,25 +0,0 @@
|
|
|
1
|
-
# Variable: HealthStatus
|
|
2
|
-
|
|
3
|
-
> `const` **HealthStatus**: `object`
|
|
4
|
-
|
|
5
|
-
The health status of the component.
|
|
6
|
-
|
|
7
|
-
## Type Declaration
|
|
8
|
-
|
|
9
|
-
### Ok {#ok}
|
|
10
|
-
|
|
11
|
-
> `readonly` **Ok**: `"ok"` = `"ok"`
|
|
12
|
-
|
|
13
|
-
OK.
|
|
14
|
-
|
|
15
|
-
### Warning {#warning}
|
|
16
|
-
|
|
17
|
-
> `readonly` **Warning**: `"warning"` = `"warning"`
|
|
18
|
-
|
|
19
|
-
Warning.
|
|
20
|
-
|
|
21
|
-
### Error {#error}
|
|
22
|
-
|
|
23
|
-
> `readonly` **Error**: `"error"` = `"error"`
|
|
24
|
-
|
|
25
|
-
Error.
|