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

monacore

v0.1.35

Published

Monacoin Library

Downloads

12

Readme

Monacore

Build Status Coverage Status

A pure, powerful core for your monacoin project.

Monacore is a complete, native interface to the Monacoin network, and provides the core functionality needed to develop apps for monacoin.

#Principles

Monacoin is a powerful new peer-to-peer platform for the next generation of financial technology. The decentralized nature of the Monacoin network allows for highly resilient monacoin infrastructure, and the developer community needs reliable, open-source tools to implement monacoin apps and services.

Monacore unchains developers from fallible, centralized APIs, and provides the tools to interact with the real Monacoin network.

#Get Started

Monacore runs on node, and can be installed via npm:

npm install monacore

It is a collection of objects useful to monacoin applications; class-like idioms are enabled via Soop. In most cases, a developer will require the object's class directly. For instance:

var monacore = require('monacore');
var Address = monacore.Address;
var Transaction = monacore.Transaction;
var PeerManager = monacore.PeerManager;

#Examples

Examples are provided here Build the examples by installing and running gulp:

npm install -g gulp
gulp

Javascript files available at /examples folder.

#Security

Please use at your own risk.

Monacore is still under heavy development and not quite ready for "drop-in" production use. If you find a security issue, please email [email protected].

#Contributing

Monacore needs some developer love. Please send pull requests for bug fixes, code optimization, and ideas for improvement.

#Browser support

Building the browser bundle

To build monacore full bundle for the browser (this is automatically executed after you run npm install):

node browser/build.js -a

This will generate a browser/bundle.js file which you can include in your HTML to use monacore in the browser.

##Example browser usage

From example/simple.html

<!DOCTYPE html>
<html>
  <body>
    <script src="../browser/bundle.js"></script>
    <script>
      var monacore = require('monacore');
      var Address = monacore.Address;
      var a = new Address('1KerhGhLn3SYBEQwby7VyVMWf16fXQUj5d');
      console.log('1KerhGhLn3SYBEQwby7VyVMWf16fXQUj5d is valid? '+a.isValid());
    </script>
  </body>
</html>

You can check a more complex usage example at examples/example.html.

Generating a customized browser bundle

To build the main bitcore bundle, run:

node browser/build.js -m

To build all features into the bitcore bundle (which will lead to a large filesize), run:

node browser/build.js -a

To generate a customized bitcore bundle, you can specify which submodules you want to include in it with the -s option:

node browser/build.js -s Transaction,Address

This will generate a browser/bundle.js containing only the Transaction and Address class, with all their dependencies. Use this option if you are not using the whole monacore library, to optimize the bundle size, script loading time, and general resource usage.

Tests

Run tests in node:

mocha

Or generate tests in the browser:

grunt shell

And then open test/index.html in your browser.

To run the code coverage report:

npm run-script coverage

And then open coverage/lcov-report/index.html in your browser.

#License

Code released under the MIT license.

Copyright 2013-2014 BitPay, Inc. Monacore is a trademark maintained by BitPay, Inc.

Bitdeli Badge