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

@marcoslobo/poma-nep9

v1.0.0

Published

Poma-NEP9 Module

Downloads

3

Readme

neon-nep9

Overview

Poma-NEP9 plugin. Adds the package nep9 into poma-core.

  • Ability to parse an NEP9 compliant string into an easily consumable intent object

Installation

yarn i @marcoslobo/poma-nep9 @marcoslobo/poma-core
const neonCore = require("@marcoslobo/poma-core");
const nep9Plugin = require("@marcoslobo/poma-nep9");

const neonJs = nep9Plugin(neonCore);

module.exports = neonJs;

API

parse takes in a complete NEP9 URI string and returns an intent object:

import { nep9 } from "pomaJs";
const intent = parse(
  "poma:AeNkbJdiMx49kBStQdDih7BzfDwyTNVRfb?asset=gas&amount=123.456"
);

The intent will look like:

{
  address: "AeNkbJdiMx49kBStQdDih7BzfDwyTNVRfb",
  attributes:[], // defaults to empty array
  asset: "602c79718b16e442de58778e148d0b1084e3b2dffd5de6b7b16cee7969282de7", // May be undefined
  amount: 123.456 // May be undefined
}
  • Known ASCII attributes (remarks and descriptions) are URI-decoded and transformed into hexstrings automatically.
  • Assets poma and gas are automatically transformed into their respective assetIds.
  • Runtime validation such as address and contract verifications are not performed during parsing.