devtape-core
v0.1.4
Published
DevTape core — dev-only browser flight recorder for causal error evidence timelines, redaction, and JSON/Markdown export
Downloads
1,035
Maintainers
Readme
devtape-core
DevTape core — dev-only browser flight recorder for causal error evidence timelines, redaction, and JSON/Markdown/AI prompt export.
Install
npm install devtape-coreUsage
import { FailureRecorder, exportJson, exportMarkdown, exportAiPrompt } from "devtape-core";
const recorder = new FailureRecorder({
sessionId: "my-session",
redaction: { keys: ["authorization", "token"] },
failedStatuses: [401, 403, 500],
});
recorder.record({ kind: "interaction", metadata: { type: "click" } });
// ... on error or failed HTTP status, evidence freezes automatically
const bundle = recorder.getLastFrozen();
if (bundle) {
exportJson(bundle);
exportMarkdown(bundle);
exportAiPrompt(bundle);
}What it does
- Ring buffer of typed timeline events (interactions, navigation, console, network, errors)
- Redacts sensitive values before storage
- Freezes an evidence bundle on unhandled errors, rejections, or configured HTTP failures
- Exports JSON, Markdown, and AI-ready prompts (correlations are evidence, not root cause)
Related packages
| Package | Purpose | |---------|---------| | devtape-browser | Browser instrumentation | | devtape-viewer | Docked overlay UI | | devtape-react | React provider + error boundary | | devtape-nextjs | Next.js navigation adapters | | devtape-cli | Offline bundle viewer |
License
MIT
