@xtandard/audit/hooks/log
A reference hook: createLogHook() logs mutation events. A starting point
for your own after side effects. Zero dependencies.
import { … } from "@xtandard/audit/hooks/log";Functions
Section titled “Functions”| Name | Summary |
|---|---|
createLogHook |
Build a hook that logs each mutation 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 — after only), json (one JSON object per line), describe (an extra text-format field) and format (replaces the whole line; default [@xtandard/audit] <phase> <type> <json>). |