near-sdk-as v3.2.3
near-sdk-as
Collection of packages used in developing NEAR smart contracts in AssemblyScript including:
runtime library- AssemblyScript near runtime librarybindgen- AssemblyScript transformer that adds the bindings needed to (de)serialize input and outputs.near-mock-vm- Core of the NEAR VM compiled to WebAssembly used for running unit tests.@as-pect/cli- AssemblyScript testing framework similar to jest.
To Install
yarn add -D near-sdk-asProject Setup
To set up a AS project to compile with the sdk add the following asconfig.json file to the root:
{
"extends": "near-sdk-as/asconfig.json"
}Then if your main file is assembly/index.ts, then the project can be build with asbuild:
yarn asbwill create a release build and place it ./build/release/<name-in-package.json>.wasm
yarn asb --target debugwill create a debug build and place it in ./build/debug/..
Testing
Unit Testing
See the sdk's as-pect tests for an example of creating unit tests. Must be ending in .spec.ts in a assembly/__tests__.
License
near-sdk-as is distributed under the terms of both the MIT license and the Apache License (Version 2.0).
See LICENSE-MIT and LICENSE-APACHE for details.
4 years ago
4 years ago
4 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago
6 years ago