npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

owallet.js

v0.0.7

Published

Very lightweight Obyte wallet. It works everywhere where you can run JS.

Downloads

3

Readme

owallet.js

Very lightweight Obyte wallet. It works everywhere where you can run JS.

If something didn't work - write me, I'll fix it :)

!!! Support only single address wallet and does not support private assets !!!

How to start?

Node.js

$ yarn add owallet.js

index.js

const Wallet = require('owallet.js');
const w = new Wallet(null, true); // testnet

(async () => {
    await w.init();
    w.connect();
    console.log(await w.createWallet('password'));
    console.log(w.getAddress());
    console.log(await w.getBalance());
})();

Browser

CDN

wallet + generator

<script src="https://unpkg.com/[email protected]/dist/owallet.all.min.js"></script>

wallet and generator (separately). Generator needs only for creating and recovery wallet.

<script src="https://unpkg.com/[email protected]/dist/owallet.generator.min.js"></script>
<script src="https://unpkg.com/[email protected]/dist/owallet.lib.min.js"></script>

build

$ git clone https://github.com/olabs-org/owallet.js
$ cd owallet.js
$ yarn
$ yarn all
$ yarn generator
$ yarn lib

See CDN.

Functions

Create
const w = new Wallet();

Optional arguments

  • hub url (wss://obyte.org/bb)
  • testnet (boolean)
init

Initializes work with storage

await w.init();
connect

Connect to hub

w.connect();

Optional argument

  • testnet (need for change network)

Change network:

w.close();
w.connect(true);
await w.init();    
close

Close connection to hub

w.close()
createWallet

Create and save wallet

await w.createWallet('password');

Required argument

  • password (string)
recoveryWallet

Recover and save wallet

await w.recoveryWallet('gospel oak horn excite wheat mountain remove embody school confirm fossil mad', 'password');

Required arguments

  • Seed (string)
  • password (string)
getAddress

return obyte address

w.getAddress();
getBalance

return balance

await w.getBalance();
sendPayment
await w.sendPayment('password', '5Q7MD7AHC2MSNGSHHBHPKVHPD2VFDB22', 1234);

Required arguments

  • password (string)
  • address (string)
  • amount (string)

Optional argument

  • asset (string)
sendMultiPayment
await w.sendMultiPayment('password', [{address: '5Q7MD7AHC2MSNGSHHBHPKVHPD2VFDB22', amount: 1234}]);

Required arguments

  • password (string)
  • outputs (array)

Optional argument

  • asset (string)
postDataInAA

Publishes data in AA

await w.postDataInAA('test', 'RQ46GHBRQWJJMWLZTVF2GH4A5QOLXFOV', {'var': 'qwerty'}, 11000)

Required arguments

  • password (string)
  • aa address (string)
  • data (object)
  • amount (number > 10000)
getRawHistory

return history from hub

await w.getRawHistory();
getHistoryPayments

return prepared payment history

await w.getHistoryPayments()

Questions? Help is needed? @xjenek - telegram, xJeneK#3181 - discord