near-sdk 5.28.2

Rust library for writing NEAR smart contracts.
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
//! Regular smart contract.

use near_sdk::near;

#[near(contract_state)]
#[derive(Default)]
struct Incrementer {
    value: u32,
}

#[near]
impl Incrementer {
    pub fn inc(&mut self, by: u32) {
        self.value += by;
    }
}

fn main() {}