0.1.0-pre.0 • Published 1 year ago

substrate-signer-provider-plugin-js v0.1.0-pre.0

Weekly downloads
-
License
SEE LICENSE IN LI...
Repository
-
Last release
1 year ago

Subscript Browser Signer Provider

This is a Polywrap plugin for accessing the accounts and signing services provided by a browser with the polkadot-js browser extension installed.

It exposes a minimal interface

  • getAccounts - List the accounts managed by the plugin
  • signPayload - Sign a structured extrinsic payload
  • signRaw - Sign a string of raw bytes

It is preferable to use signPayload when possible as it allows the extension to display much more useful information to the user about what they are signing.

Developer Setup

After setting up the yarn workspace from the /substrate root run:

yarn

Building

Build uses the polywrap CLI tool:

yarn build

Testing

Integration tests (plugin with mock browser extension) can be run with:

yarn test