@envelop/core 5.0.0 → 5.0.1
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 +1 -0
- package/cjs/index.js +1 -0
- package/cjs/plugins/use-validation-rule.js +11 -0
- package/esm/index.js +1 -0
- package/esm/plugins/use-validation-rule.js +7 -0
- package/package.json +1 -1
- package/typings/index.d.cts +1 -0
- package/typings/index.d.ts +1 -0
- package/typings/plugins/use-validation-rule.d.cts +2 -0
- package/typings/plugins/use-validation-rule.d.ts +2 -0
package/README.md
CHANGED
package/cjs/index.js
CHANGED
|
@@ -14,5 +14,6 @@ tslib_1.__exportStar(require("./plugins/use-extend-context.js"), exports);
|
|
|
14
14
|
tslib_1.__exportStar(require("./plugins/use-payload-formatter.js"), exports);
|
|
15
15
|
tslib_1.__exportStar(require("./plugins/use-masked-errors.js"), exports);
|
|
16
16
|
tslib_1.__exportStar(require("./plugins/use-engine.js"), exports);
|
|
17
|
+
tslib_1.__exportStar(require("./plugins/use-validation-rule.js"), exports);
|
|
17
18
|
var document_string_map_js_1 = require("./document-string-map.js");
|
|
18
19
|
Object.defineProperty(exports, "getDocumentString", { enumerable: true, get: function () { return document_string_map_js_1.getDocumentString; } });
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.useValidationRule = void 0;
|
|
4
|
+
const useValidationRule = (rule) => {
|
|
5
|
+
return {
|
|
6
|
+
onValidate({ addValidationRule }) {
|
|
7
|
+
addValidationRule(rule);
|
|
8
|
+
},
|
|
9
|
+
};
|
|
10
|
+
};
|
|
11
|
+
exports.useValidationRule = useValidationRule;
|
package/esm/index.js
CHANGED
|
@@ -10,4 +10,5 @@ export * from './plugins/use-extend-context.js';
|
|
|
10
10
|
export * from './plugins/use-payload-formatter.js';
|
|
11
11
|
export * from './plugins/use-masked-errors.js';
|
|
12
12
|
export * from './plugins/use-engine.js';
|
|
13
|
+
export * from './plugins/use-validation-rule.js';
|
|
13
14
|
export { getDocumentString } from './document-string-map.js';
|
package/package.json
CHANGED
package/typings/index.d.cts
CHANGED
|
@@ -9,4 +9,5 @@ export * from './plugins/use-extend-context.cjs';
|
|
|
9
9
|
export * from './plugins/use-payload-formatter.cjs';
|
|
10
10
|
export * from './plugins/use-masked-errors.cjs';
|
|
11
11
|
export * from './plugins/use-engine.cjs';
|
|
12
|
+
export * from './plugins/use-validation-rule.cjs';
|
|
12
13
|
export { getDocumentString } from './document-string-map.cjs';
|
package/typings/index.d.ts
CHANGED
|
@@ -9,4 +9,5 @@ export * from './plugins/use-extend-context.js';
|
|
|
9
9
|
export * from './plugins/use-payload-formatter.js';
|
|
10
10
|
export * from './plugins/use-masked-errors.js';
|
|
11
11
|
export * from './plugins/use-engine.js';
|
|
12
|
+
export * from './plugins/use-validation-rule.js';
|
|
12
13
|
export { getDocumentString } from './document-string-map.js';
|