Arbitrum Stylus

Integrate thirdweb tools in Stylus contract (Rust) development workflow.

Use thirdweb CLI to create, publish, and deploy contracts written with Stylus. The deployed contracts can be used via thirdweb dashboard or SDK.

Prerequisites

You can also use the Stylus quickstart guide for reference: https://docs.arbitrum.io/stylus/quickstart

Getting started

To get started, setup a starter repo (can be skipped if you already have a Stylus project):

npx thirdweb create-stylus

This will setup a project containing a template contract.

Publishing and Deploying

Use one of these commands to publish or deploy your Stylus contract.

npx thirdweb publish-stylus -k <YOUR SECRET KEY>

OR

npx thirdweb deploy-stylus -k <YOUR SECRET KEY>

Publishing a contract saves the contract metadata to an onchain registry, and creates a contract page from where you can deploy a specific version of this contract multiple times.

This is what you should see:

After deployment, the contract will be available on thirdweb dashboard. You can interact with it via dashboard or integrate it in your app using the code snippets as shown below:

More templates for Stylus Rust contracts and use-case specific installable modules are coming soon.