Building Smart Contracts

Install cargo-contract

To build the Substrate smart contract project we will need CLI utility

rustup component add rust-src --toolchain nightly
cargo install cargo-contract --vers ^0.8 --force --locked

๐Ÿงช Test

To test the smart contract, run the following command

cargo +nightly test

๐Ÿ—๏ธ Build

To compile the smart contract, run the following command

cargo +nightly contract build

Last updated