@xtandard/entitlements/hooks/log
A reference hook: createLogHook() logs control-plane events (text or one
JSON object per line). A starting point for your own after side effects.
Zero dependencies.
import { … } from "@xtandard/entitlements/hooks/log";Functions
Section titled “Functions”| Name | Summary |
|---|---|
createLogHook |
Build a hook that logs each control-plane event. Never throws from before, so it never denies a mutation — it is a pure observer. |
Type aliases
Section titled “Type aliases”| Name | Summary |
|---|---|
LogHookOptions |
Options for createLogHook: log (default console.log), includeBefore (default false), json (one { source, phase, ...event } object per line) and format. The default text line is [@xtandard/entitlements] <phase> <type> <customer> + the JSON payload. |