lsp4-contracts: v0.15.0
0.15.0 (2024-04-05)
Package for the LSP4 Digital Asset Metadata standard.
Installation
npm install @lukso/lsp4-contracts
Type-safe ABIs, contract interfaces and React Hooks
This release includes new type-safe features generated by wagmi:
- ABIs + typed events
import {
lsp4DigitalAssetMetadataAbi,
lsp4DigitalAssetMetadataInitAbstractAbi
} from "@lukso/lsp4-contracts/types";
- React hooks
- contract Interfaces (based on Viem types) including the following helper functions:
getFunction(...)
getEvent(...)
encodeFunctionData(...)
decodeFunctionData(...)
To see all the React hooks available for the LSP4 contracts, you can look at the file
@lukso/lsp4-contracts/types/index.ts
under yournode_modules
dependencies.
Available Constants & Types
The @lukso/lsp4-contracts
npm package contains useful constants such as ERC725Y Data Keys related to the LSP4 Standard. You can import and access them as follow:
import {
LSP4_TOKEN_TYPES,
LSP4SupportedStandard,
LSP4DataKeys,
LSP4DigitalAssetMetadataJSON,
LSP4DigitalAssetMetadata,
LinkMetadata,
ImageMetadata,
AssetMetadata,
AttributeMetadata,
} from "@lukso/lsp4-contracts";
Miscellaneous Chores
- release lsp-smart-contracts 0.15.0 (fbbd048)