{"repo":"nimiq/electrum-client","free":true,"listed":false,"github":"https://github.com/nimiq/electrum-client","clone":"git clone https://github.com/nimiq/electrum-client.git","description":"API to interact with ElectrumX servers from browsers","language":"TypeScript","stars":14,"topics":["bitcoin","electrum","electrumx","websocket"],"license":null,"category":"blockchain-web3","readme_excerpt":"Electrum API for Browsers Access Bitcoin ElectrumX servers from browsers via a WebSocket-to-TCP proxy. Installation There is no NPM package yet, so you need to set the #build branch of this repo as the package source: Providing bitcoinjs-lib @nimiq/electrum-client depends on bitcoinjs-lib which makes use of built-in modules and globals native to NodeJS. For use in browsers, they must be polyfilled as part of the build process. Note that @nimiq/electrum-client does not include these polyfills as it does not even bundle bitcoinjs-lib . This is to avoid duplicate bundling of bitcoinjs-lib and the polyfills, if your app itself bundles bitcoinjs-lib or the polyfills, too. This way, also no polyfills are unnecessarily included if using the library in NodeJs instead of a browser, and specific polyfills can be picked by the app author. Example instructions for bundling the polyfills with various bundlers follow in the next sections, roughly sorted from easiest to set up but least preferable to harder to set up but preferable. browserify browserify supports bundling apps with polyfills. You can either use it to bundle your entire app, or to bundle just the @nimiq/electrum-client as a standalone file. The following example bundles the lib to a standalone file: Note that bundling to a separate file can lead to duplicate bundling of bitcoinjs-lib and the polyfills between the standalone file and the rest of your app. Therefore, using a different bundler is recommended. rollup with plugin","default_branch":null,"files":null,"tree":[],"storefront":"/r/nimiq","claimed":false,"request_supported":{"post":"https://gitbuyer.com/r/nimiq/electrum-client/request-supported","requests":0},"note":"indexed from public GitHub; nothing is for sale on this page. Clone it from GitHub. Paid listings live at /search."}