This is a Typedoc plugin that allows you to load BitcoinJS in a web page and run code online.
- Install the plugin:
npm install typedoc-plugin-bitcoinjs-runcase --save-dev
- Add the plugin to your Typedoc configuration:
{
"plugins": ["typedoc-plugin-bitcoinjs-runcase"]
}
- In your code comments, use @case tag to mark code blocks that should be runnable:
/**
* This is an example of using BitcoinJS.
*
* @case
* ```typescript
* console.log('address:toBech32:::');
* console.log(address.toBech32('751e76e8199196d454941c45d1b3a323', 2, 'bc'))
* ```
*/
- Plugin build result
- You can edit your case and run it!