0.3.8 • Published 3 months ago

ink-generator v0.3.8

Weekly downloads
-
License
Apache-2.0
Repository
github
Last release
3 months ago

logoVMov-sm

A WASM module for generating smart contract code in ink!

Built with 🦀 by:

About

This repository is the main implementation of the rust code generator. It can produce code ready for deployment based on code fragments located here. This implementation uses syn rust crate. It is designed to be used as a web-assembly module executed on the client side.

Be sure to check out other wasm-pack tutorials online for other templates and usages of wasm-pack.

🛠️ Build with wasm-pack build

wasm-pack build

🔬 Test in Headless Browsers with wasm-pack test

wasm-pack test --headless --firefox

🎁 Publish to NPM with wasm-pack publish

wasm-pack publish

🛠️ Testing merged Smart Contracts code

First generate code of merged contracts:

cargo run init

It will create code of the SC with tested extension and save it to contracts/[STANDARD]/extension/tests/[EXTENSION]/src directory.

This command uses the same method as our front-end tool, so the code being tested is the same as the one that you can see.

Then run this command:

cargo test --manifest-path contracts/Cargo.toml --features "contract","test-only"

🚴 Usage

For details about integrating compiled wasm module into your front-end app see this docs

🔋 Batteries Included

  • wasm-bindgen for communicating between WebAssembly and JavaScript.
  • console_error_panic_hook for logging panic messages to the developer console.
  • LICENSE-APACHE and LICENSE-MIT: most Rust projects are licensed this way, so these are included for you

License

Licensed under:

Contribution

Please check Contributing docs for details.

0.3.8

3 months ago

0.3.7

3 months ago

0.3.6

4 months ago

0.3.5

5 months ago

0.3.4

5 months ago

0.3.3

5 months ago

0.3.2

6 months ago

0.3.1

6 months ago

0.3.0

6 months ago

0.1.0

6 months ago