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

@chromia/ft4

v0.7.0

Published

FT4 Library is a library for Rell modules (Chromia smart contract language). It can be imported and used as a token provider and manager. It allows several operations, among them: creation of different assets (type of tokens), allocation of tokens, transf

Downloads

783

Readme

FT4 Library: Asset and Account Management for Chromia's Rell and TypeScript Environments

Introduction

The FT4 Library functions as a comprehensive toolkit engineered for both Rell and TypeScript modules in the Chromia blockchain ecosystem. Specialising in asset and account management, the library provides a suite of operations including asset issuance, allocation, and transfers, extending even to cross-chain capabilities. Furthermore, it establishes foundational data structures for account management, designed to operate independently of asset-related activities.

Features

  • Asset Management: Facilitate the creation, allocation, and management of assets. Asset Allocation and Transfers: Perform secure and efficient asset transfers.
  • Cross-Chain Transfers: Enable the movement of assets between distinct blockchains.
  • Account Management: Oversee user accounts independently of asset activities.

Repository Overview

This repository contains the FT4 library and a comprehensive suite of tests written in Node.js and Jest. The current testing setup serves as a temporary measure, as a Rell-based testing suite is in development.

Getting Started

Prerequisites

  • Node.js
  • Docker
  • [Optional] PostgreSQL for database sessions

Installation

Clone the repository and install the dependencies:

git clone [email protected]:chromawallet/ft3-lib.git
cd ft3-lib
npm install

Build

Build TypeScript library into dist/:

npm run build

How to Run Tests

Comprehensive Test Suite

Run the complete set of Rell and TypeScript tests:

npm run test

Run only Rell or TypeScript tests:

npm run test:rell
npm run test:js

Running Specific Rell Tests

To execute particular tests in Rell, use the --tests or -t option:

npm run test:rell -- --tests=test1,test2
npm run test:rell -- -t=test1,test2

Running Specific Jest Tests

Execute specific Jest tests by string matching:

npm run test:js 'string matching test(s)'

Examples:

npm run test:js 'user'
npm run test:js 'rate|sso'

Running End-to-End Tests with Cypress

Interactive Mode

Run e2e tests interactively:

npm run test:e2e

Headless Mode

Run e2e tests in headless mode:

npm run test:e2e:headless

How to Run the Blockchain

For running different blockchain configurations, you can use the following npm commands:

  • Test Environment: npm run postchain:test
  • Demo Environment: npm run postchain:demo

To stop these environments:

  • Test: npm run stop-postchain:jest
  • Demo: npm run stop-postchain:demo

Changelog

Update changelog in doc/release-notes/, then run ./compile-changelog.sh script to assemble changelog.md and rell-changelog.md. Do not update changelog.md or rell-changelog.md directly.

License

This project is licensed under the Apache License, Version 2.0. For more details, see the LICENSE file in the repository or visit Apache License, Version 2.0.