@gorules/zen-engine 0.2.0 → 0.3.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/index.d.ts +3 -5
- package/package.json +7 -7
package/index.d.ts
CHANGED
|
@@ -7,17 +7,15 @@ export interface ZenEvaluateOptions {
|
|
|
7
7
|
maxDepth?: number
|
|
8
8
|
trace?: boolean
|
|
9
9
|
}
|
|
10
|
-
export interface
|
|
10
|
+
export interface ZenEngineOptions {
|
|
11
11
|
loader?: (key: string) => Promise<Buffer>
|
|
12
12
|
}
|
|
13
|
-
export type JsZenDecision = ZenDecision
|
|
14
13
|
export class ZenDecision {
|
|
15
14
|
constructor()
|
|
16
|
-
evaluate(context: any, opts?:
|
|
15
|
+
evaluate(context: any, opts?: ZenEvaluateOptions | undefined | null): Promise<any>
|
|
17
16
|
}
|
|
18
|
-
export type JsZenEngine = ZenEngine
|
|
19
17
|
export class ZenEngine {
|
|
20
|
-
constructor(options?:
|
|
18
|
+
constructor(options?: ZenEngineOptions | undefined | null)
|
|
21
19
|
evaluate(key: string, context: any, opts?: ZenEvaluateOptions | undefined | null): Promise<any>
|
|
22
20
|
createDecision(content: Buffer): ZenDecision
|
|
23
21
|
getDecision(key: string): Promise<ZenDecision>
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@gorules/zen-engine",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.3.1",
|
|
4
4
|
"main": "index.js",
|
|
5
5
|
"types": "./index.d.ts",
|
|
6
6
|
"license": "MIT",
|
|
@@ -78,12 +78,12 @@
|
|
|
78
78
|
"prepublishOnly": "napi prepublish",
|
|
79
79
|
"version": "napi version"
|
|
80
80
|
},
|
|
81
|
-
"gitHead": "
|
|
81
|
+
"gitHead": "f5fe884033073a09935b2b9483682a3645c6bc40",
|
|
82
82
|
"optionalDependencies": {
|
|
83
|
-
"@gorules/zen-engine-darwin-x64": "0.
|
|
84
|
-
"@gorules/zen-engine-linux-x64-gnu": "0.
|
|
85
|
-
"@gorules/zen-engine-win32-x64-msvc": "0.
|
|
86
|
-
"@gorules/zen-engine-linux-arm64-gnu": "0.
|
|
87
|
-
"@gorules/zen-engine-darwin-arm64": "0.
|
|
83
|
+
"@gorules/zen-engine-darwin-x64": "0.3.1",
|
|
84
|
+
"@gorules/zen-engine-linux-x64-gnu": "0.3.1",
|
|
85
|
+
"@gorules/zen-engine-win32-x64-msvc": "0.3.1",
|
|
86
|
+
"@gorules/zen-engine-linux-arm64-gnu": "0.3.1",
|
|
87
|
+
"@gorules/zen-engine-darwin-arm64": "0.3.1"
|
|
88
88
|
}
|
|
89
89
|
}
|