@lukso/lsp-utils
TypeScript icon, indicating that this package has built-in type declarations

0.2.0 • Public • Published

LSP Smart Contracts Utils · npm version

This package was created with the intent to help developers to use @lukso/lsp-smart-contracts. Its purpose is to provide a series of helper functions for each LSP.

⚠️ This package is currently in early stages of development,
use for testing or experimentation purposes only.

Installation

npm

@lukso/lsp-utils is available as a npm package.

npm install @lukso/lsp-utils

cloning the repository

Alternatively you can also clone the repository and install its dependencies to start using the smart contracts.

$ git clone https://github.com/lukso-network/lsp-utils.git
$ cd ./lsp-utils
$ npm install

Usage

in Javascript

You can use the utils by importing them as follow:

ES6 Modules:

import { encodeAllowedCalls } from '@lukso/lsp-utils/dist/lib/es6';

const allowedCalls = encodeAllowedCalls(
    allowedInteractions,
    allowedAddresses,
    allowedStandards,
    allowedFunctions,
);

CommonJS

cosnt { encodeAllowedCalls } = require('@lukso/lsp-utils/dist/lib/es5');

const allowedCalls = encodeAllowedCalls(
    allowedInteractions,
    allowedAddresses,
    allowedStandards,
    allowedFunctions
);

Documentation

For more informations check the docs folder

Package Sidebar

Install

npm i @lukso/lsp-utils

Weekly Downloads

16

Version

0.2.0

License

MIT

Unpacked Size

17.2 MB

Total Files

9

Last publish

Collaborators

  • lukso-network
  • frozeman