JSPM

  • ESM via JSPM
  • ES Module Entrypoint
  • Export Map
  • Keywords
  • License
  • Repository URL
  • TypeScript Types
  • README
  • Created
  • Published
  • Downloads 4
  • Score
    100M100P100Q53012F
  • License MIT

Package Exports

  • subsh
  • subsh/dist/index.js

This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (subsh) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.

Readme

Subshell

Interactive Polkadot.js REPL for Your Substrate Node.

NPM version NPM downloads Subshell Discussion

Subshell at its core is a simple cli tool wrapping the following lines of code.

#!/usr/bin/env -S node --experimental-repl-await
const { ApiPromise, WsProvider } = require(`@polkadot/api`)
const provider = new WsProvider(`wss://polkadot.api.onfinality.io/public-ws`);
const types={};
api = await ApiPromise.create({ provider, types});
...

Thanks to esbuild and vm2, it can execute snippets written in ts/mjs/js, and load dependencies from urls like what deno does.

It's still under active development, so expect breaking changes.

There is an online version hosted at https://subshell.xyz for you to play with.

Install

$ npm install -g subsh

Run

$ subsh --provider wss://rpc.polkadot.io

Features

🚧 UNDER CONSTRUCTION 🚧

For more documentation, visit doc.subshell.xyz

License

The author disclaims copyright to this source code. In place of a legal notice, here is a blessing:

  May you do good and not evil.
  May you find forgiveness for yourself and forgive others.
  May you share freely, never taking more than you give.