npm.io
2.0.0 • Published 1 month ago

@metamask/delegation-abis

Licence
(MIT-0 OR Apache-2.0)
Version
2.0.0
Deps
0
Size
6.1 MB
Vulns
0
Weekly
0
Stars
63

Delegation ABIs

A collection of ABIs for the Delegation Framework. Versioning will be unique to commit hashes of the contracts repo.

Installation

This package is normally installed as part of the Smart Accounts Kit (@metamask/smart-accounts-kit) which is part of this monorepo.

In order to install this package standalone:

With yarn:

yarn add @metamask/delegation-abis

With npm:

npm install @metamask/delegation-abis

Updating the Delegation Framework and ABIs

In order to update the contracts and ABIs from the Delegation Framework, follow these steps:

1. Update the submodule
a. Navigate into the Delegation Framework submodule:
cd ../../lib/delegatable-framework/
b. Fetch the latest changes
git fetch
c. Update to the specific commit or latest
git checkout <specific-commit>

or

git checkout main
git pull
2. Generate the ABIs

The generate.sh script will build the contracts, outputting ABIs and generate typescript files containing the ABIs. The typescript files are how the ABIs are used within the Smart Accounts Kit.

 ./scripts/generate.sh

Keywords