mirror of
https://github.com/microsoft/regorus.git
synced 2026-08-05 02:16:11 +00:00
Extend prepare API/docs across bindings
Agent-Logs-Url: https://github.com/microsoft/regorus/sessions/49ba4462-95d3-42c0-a302-db1b81df4f65 Co-authored-by: anakrish <35780660+anakrish@users.noreply.github.com>
This commit is contained in:
committed by
GitHub
parent
72515f6d4c
commit
730e6de75a
@@ -23,4 +23,7 @@ Run `cargo xtask build-wasm` to invoke wasm-pack with sensible defaults, or `car
|
||||
See [test.js](https://github.com/microsoft/regorus/blob/main/bindings/wasm/test.js) for example usage.
|
||||
|
||||
For best performance with large policies, call `engine.prepare()` after loading
|
||||
policy/data, then use `engine.clone()` to create per-request engines.
|
||||
policy/data, then use `engine.clone()` to create per-request engines. If
|
||||
`prepare()` is skipped, the first `eval*` call performs the same one-time
|
||||
setup. Adding/changing policy or data after `prepare()` invalidates the
|
||||
prepared state.
|
||||
|
||||
Reference in New Issue
Block a user