{"repo":"OffchainLabs/stylus-hello-world","free":true,"listed":false,"github":"https://github.com/OffchainLabs/stylus-hello-world","clone":"git clone https://github.com/OffchainLabs/stylus-hello-world.git","description":"Project starter template for writing Arbitrum Stylus programs in Rust","language":"Rust","stars":54,"topics":[],"license":null,"category":"saas-starters-boilerplates","readme_excerpt":"Stylus Hello World Project starter template for writing Arbitrum Stylus programs in Rust using the stylus-sdk. It includes a Rust implementation of a basic counter Ethereum smart contract: To set up more minimal example that still uses the Stylus SDK, use cargo stylus new --minimal under OffchainLabs/cargo-stylus. Quick Start Install Rust, and then install the Stylus CLI tool with Cargo Add the wasm32-unknown-unknown build target to your Rust compiler: You should now have it available as a Cargo subcommand: Then, clone the template: Testnet Information All testnet information, including faucets and RPC endpoints can be found here. ABI Export You can export the Solidity ABI for your program by using the cargo stylus tool as follows: which outputs: Exporting ABIs uses a feature that is enabled by default in your Cargo.toml: Deploying You can use the cargo stylus command to also deploy your program to the Stylus testnet. We can use the tool to first check our program compiles to valid WASM for Stylus and will succeed a deployment onchain without transacting. By default, this will use the Stylus testnet public RPC endpoint. See here for Stylus testnet information If successful, you should see: Next, we can estimate the gas costs to deploy and activate our program before we send our transaction. Check out the cargo-stylus README to see the different wallet options for this step: You will then see the estimated gas cost for deploying before transacting: The above only estimates gas","default_branch":null,"files":null,"tree":[],"storefront":"/r/OffchainLabs","claimed":false,"request_supported":{"post":"https://gitbuyer.com/r/OffchainLabs/stylus-hello-world/request-supported","requests":0},"note":"indexed from public GitHub; nothing is for sale on this page. Clone it from GitHub. Paid listings live at /search."}