@polkadot-api/logs-provider
TypeScript icon, indicating that this package has built-in type declarations

0.0.2 • Public • Published

@polkadot-api/logs-provider

This package exports a JsonRpcProvider enhancer to record logs of messages sent & received, and a provider that reads from these logs to replay existing sessions.

This can be useful to set up reproduction cases with a provider that behaves consistently.

withLogsRecorder

function withLogsRecorder(
  persistLog: (line: string) => void,
  provider: JsonRpcProvider,
): JsonRpcProvider

logsProvider

function logsProvider(logs: string[]): JsonRpcProvider

Readme

Keywords

none

Package Sidebar

Install

npm i @polkadot-api/logs-provider

Weekly Downloads

558

Version

0.0.2

License

MIT

Unpacked Size

41.4 kB

Total Files

12

Last publish

Collaborators

  • voliva
  • josepot