Overview
The Trezo CLI is the fastest way to get started with building multi-chain Trezo dApps.
- Fetching curated templates from a remote registry
- Cloning production-ready starters into your local environment
- Guiding you through a simple, interactive setup process
This ensures that every project follows a consistent structure and developer experience, regardless of the blockchain or framework you choose.
Initialize a Project
pnpm dlx trezo init
This command starts an interactive setup that walks you through creating your project step-by-step.
Commands
trezo init
Initialize a new Trezo-powered Web3 project.
trezo init [options]What It Does
- Prompts you to select a blockchain package
- Lets you choose a starter template
- Clones the selected template into your local machine
- Prepares your project with all required dependencies and configurations
Options
-
-n, --name <name>Specify the project name (and directory). If omitted, you will be prompted. -
-p, --package <name>Skip package selection and directly use a specific package (e.g.@trezo/evm). -
-t, --template <name>Skip template selection and use a predefined template (e.g.vite-app).
Interactive Flow
When no flags are provided, the CLI guides you through:
-
Package Selection Choose the blockchain ecosystem you want to build on.
-
Template Selection Pick a starter template (e.g., Vite, Next.js).
-
Project Naming Confirm or customize your project directory.
-
Project Scaffolding The selected template is cloned and configured automatically.
Example Usage
# Fully interactive
trezo init
# Skip prompts using flags
trezo init -n my-dapp -p @trezo/evm -t vite-app
# Full explicit usage
trezo init --name my-dapp --package @trezo/evm --template vite-apptrezo list
View all available Trezo packages and templates.
pnpm dlx trezo list
What It Shows
- Available Trezo packages (e.g., EVM, Starknet)
- Supported templates under each package
- Template identifiers for CLI usage
Example Output
ā Found 2 package(s)
š¦ @trezo/evm ā EVM { package: @trezo/evm }
āā Next.js ā next-app
āā Vite ā vite-app
š¦ @trezo/strk ā Starknet { package: @trezo/strk }
āā Starknet React ā strk-react
ā¹ Usage: trezo init -p <package> -t <template>When to Use
Use trezo list when you:
- Want to explore available templates
- Need exact package or template IDs
- Prefer non-interactive CLI usage
Generated Project
After initialization, your project comes fully set up with:
- Pre-configured Trezo integration
- Selected blockchain package installed
- Wallet connection support
- Clean and scalable project structure
- Ready-to-run development environment
You can start building immediately without worrying about boilerplate or setup complexity.
Summary
The Trezo CLI standardizes how frontend developers build Web3 applications by providing:
- A single workflow across multiple blockchains
- A consistent development experience
- A fast path from idea to working application