Crates.io | idl-macro |
lib.rs | idl-macro |
version | 0.1.0 |
source | src |
created_at | 2022-06-05 22:41:29.421778 |
updated_at | 2022-06-05 22:41:29.421778 |
description | Generates an Anchor CPI crate from a JSON IDL. |
homepage | |
repository | https://github.com/saber-hq/idl-macro |
max_upload_size | |
id | 600386 |
size | 20,648 |
Generates an Anchor CPI crate from a JSON IDL.
In a new crate, write:
idl_macro::generate_cpi_crate!("src/idl.json");
declare_id!("GjphYQcbP1m3FuDyCTUJf2mUMxKPE3j6feWU1rxvC7Ps");
This will generate a fully functional Rust CPI client for your IDL.
Apache 2.0