Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@greymass/create-account

Package Overview
Dependencies
Maintainers
0
Versions
5
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@greymass/create-account

An account creation library for Antelope chains that leverages Anchor.

  • 1.1.0
  • latest
  • npm
  • Socket score

Version published
Maintainers
0
Created
Source

Create Account Library

This library allows you to prompt the user to create and initialize an account using Anchor.

Installation

The @greymass/create-account package is distributed as a module on npm.

yarn add @greymass/create-account
# or
npm install --save @greymass/create-account

Usage

This function will automatically open a popup window prompting the user to buy an account. Once the payment is received, the account will be redirected to Anchor with an account creation code. Anchor is then expected to send a confirmation or error message back before sending the user back to the defined url.

import { AccountCreator } from '@greymass/create-account';

// Initialize the account creator object
const accountCreator = new AccountCreator({
  supportedChains: [], // List of supported chains.
  scope: 'wallet', // A string representing the scope of the account creation.
  returnUrl: 'http://wallet.greymass.com', // Url to return the user to once the account is created.
})

// Open a popup window prompting the user to create an account.
accountCreator.createAccount().then((creationResult) => {
  // Handle success, the creationResult will be an esr callback object.
}).catch((error) => {
  // Handle error
})

Developing

You need Make, node.js and yarn installed.

Clone the repository and run make to checkout all dependencies and build the project. See the Makefile for other useful targets. Before submitting a pull request make sure to run make lint.


Made with ☕️ & ❤️ by Greymass, if you find this useful please consider supporting us.

FAQs

Package last updated on 20 Dec 2024

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc