{"id":"6cc9f465-dc08-40b9-9c2a-cbbbe6c6c72b","shortId":"H766wB","kind":"skill","title":"arbitrum-dapp-skill","tagline":"Opinionated guide for building dApps on Arbitrum using Stylus (Rust) and/or Solidity. Covers local devnode setup, contract development, testing, deployment, and React frontend integration with viem. Use when starting a new Arbitrum project, writing Stylus or Solidity contracts, d","description":"# Arbitrum dApp Development\n\n## Stack\n\n| Layer | Tool | Notes |\n|-------|------|-------|\n| Smart contracts (Rust) | `stylus-sdk` v0.10+ | Compiled to WASM, runs on Stylus VM |\n| Smart contracts (Solidity) | Solidity 0.8.x + Foundry | Standard EVM path on Arbitrum |\n| Local node | `nitro-devnode` | Docker-based local Arbitrum chain |\n| Contract CLI | `cargo-stylus` | Check, deploy, export-abi for Stylus |\n| Contract toolchain | Foundry (`forge`, `cast`, `anvil`) | Build, test, deploy, interact for Solidity |\n| Frontend | React / Next.js + viem + wagmi | viem for all chain interaction |\n| Package manager | pnpm | Workspace-friendly, fast |\n\n## Decision Flow\n\nWhen starting a new contract:\n\n1. **Need max performance / lower gas?** → Stylus Rust. See `references/stylus-rust-contracts.md`.\n2. **Need broad tooling compatibility / rapid prototyping?** → Solidity. See `references/solidity-contracts.md`.\n3. **Hybrid?** → Use both. Stylus and Solidity contracts are fully interoperable on Arbitrum.\n\n## Project Scaffolding\n\n### Monorepo layout (recommended)\n\n```\nmy-arbitrum-dapp/\n├── apps/\n│   ├── frontend/            # React / Next.js app\n│   ├── contracts-stylus/    # Rust Stylus contracts\n│   ├── contracts-solidity/  # Foundry Solidity contracts\n│   └── nitro-devnode/       # Local dev chain (git submodule)\n├── pnpm-workspace.yaml\n└── package.json\n```\n\n### Bootstrap steps\n\n```bash\n# 1. Create workspace\nmkdir my-arbitrum-dapp && cd my-arbitrum-dapp\npnpm init\nprintf \"packages:\\n  - 'apps/*'\\n\" > pnpm-workspace.yaml\n\n# 2. Local devnode\ngit clone https://github.com/OffchainLabs/nitro-devnode.git apps/nitro-devnode\ncd apps/nitro-devnode && ./run-dev-node.sh && cd ../..\n\n# 3a. Stylus contract\ncargo stylus new apps/contracts-stylus\n\n# 3b. Solidity contract\ncd apps && forge init contracts-solidity && cd ..\n\n# 4. Frontend\npnpm create next-app apps/frontend --typescript\ncd apps/frontend\npnpm add viem wagmi @tanstack/react-query\n```\n\n## Core Workflow\n\n### Stylus Rust\n\n```bash\n# Validate\ncargo stylus check --endpoint http://localhost:8547\n\n# Deploy (uses the nitro-devnode pre-funded deployer account)\ncargo stylus deploy \\\n  --endpoint http://localhost:8547 \\\n  --private-key $PRIVATE_KEY\n\n# Export ABI for frontend consumption\ncargo stylus export-abi\n```\n\n### Solidity (Foundry)\n\n```bash\n# Build\nforge build\n\n# Test\nforge test\n\n# Deploy locally (uses the nitro-devnode pre-funded deployer account)\nforge script script/Deploy.s.sol --rpc-url http://localhost:8547 --broadcast \\\n  --private-key $PRIVATE_KEY\n```\n\n> **Note:** The nitro-devnode ships with a pre-funded deployer account. See `references/local-devnode.md` for the default private key and address. For testnet/mainnet, use your own key via environment variables — never hardcode secrets.\n\n### Frontend (viem + wagmi)\n\n```typescript\nimport { createPublicClient, http } from \"viem\";\nimport { arbitrumSepolia } from \"viem/chains\";\n\nconst client = createPublicClient({\n  chain: arbitrumSepolia,\n  transport: http(),\n});\n\n// Read from contract\nconst result = await client.readContract({\n  address: \"0x...\",\n  abi: contractAbi,\n  functionName: \"myFunction\",\n});\n```\n\nSee `references/frontend-integration.md` for full patterns with wagmi hooks, wallet connection, and write transactions.\n\n## Principles\n\n- **Always use viem** for chain interaction.\n- **Test locally first** against nitro-devnode before deploying to testnet.\n- **Export ABIs** from both Stylus (`cargo stylus export-abi`) and Solidity (`forge inspect`) and keep them in a shared location the frontend can import.\n- **Use environment variables** for RPC URLs, contract addresses, and private keys. Never hardcode secrets.\n- **Stylus contracts are EVM-compatible** — they share the same address space, storage model, and ABI encoding as Solidity contracts. Cross-contract calls work seamlessly.\n\n## References\n\nLoad these as needed for deeper guidance:\n\n- `references/stylus-rust-contracts.md` — Stylus SDK patterns, storage, macros, entrypoints\n- `references/solidity-contracts.md` — Solidity on Arbitrum specifics and Foundry workflow\n- `references/frontend-integration.md` — React + viem + wagmi patterns\n- `references/local-devnode.md` — Nitro devnode setup, accounts, and debugging\n- `references/deployment.md` — Deploying to testnet and mainnet\n- `references/testing.md` — Testing strategies for both Stylus and Solidity","tags":["arbitrum","dapp","skill","hummusonrails","agent-skills","claude-code-skills","claude-skills","dapp-development","ethereum","smart-contracts","solidity","stylus"],"capabilities":["skill","source-hummusonrails","skill-arbitrum-dapp-skill","topic-agent-skills","topic-arbitrum","topic-claude-code-skills","topic-claude-skills","topic-dapp-development","topic-ethereum","topic-smart-contracts","topic-solidity","topic-stylus","topic-web3"],"categories":["arbitrum-dapp-skill"],"synonyms":[],"warnings":[],"endpointUrl":"https://skills.sh/hummusonrails/arbitrum-dapp-skill","protocol":"skill","transport":"skills-sh","auth":{"type":"none","details":{"cli":"npx skills add hummusonrails/arbitrum-dapp-skill","source_repo":"https://github.com/hummusonrails/arbitrum-dapp-skill","install_from":"skills.sh"}},"qualityScore":"0.453","qualityRationale":"deterministic score 0.45 from registry signals: · indexed on github topic:agent-skills · 6 github stars · SKILL.md body (4,359 chars)","verified":false,"liveness":"unknown","lastLivenessCheck":null,"agentReviews":{"count":0,"score_avg":null,"cost_usd_avg":null,"success_rate":null,"latency_p50_ms":null,"narrative_summary":null,"summary_updated_at":null},"enrichmentModel":"deterministic:skill-github:v1","enrichmentVersion":1,"enrichedAt":"2026-05-18T19:14:49.559Z","embedding":null,"createdAt":"2026-05-18T13:22:24.258Z","updatedAt":"2026-05-18T19:14:49.559Z","lastSeenAt":"2026-05-18T19:14:49.559Z","tsv":"'/..':242 '/offchainlabs/nitro-devnode.git':236 '/run-dev-node.sh':240 '0.8':69 '0x':418 '1':136,208 '2':146,229 '3':156 '3a':243 '3b':250 '4':261 '8547':288,305,349 'abi':97,312,320,419,455,463,508 'account':299,341,368,551 'add':273 'address':377,417,486,503 'alway':437 'and/or':15 'anvil':105 'app':178,182,226,254,267 'apps/contracts-stylus':249 'apps/frontend':268,271 'apps/nitro-devnode':237,239 'arbitrum':2,11,36,44,76,86,168,176,214,219,537 'arbitrum-dapp-skil':1 'arbitrumsepolia':400,407 'await':415 'base':84 'bash':207,281,323 'bootstrap':205 'broad':148 'broadcast':350 'build':8,106,324,326 'call':516 'cargo':91,246,283,300,316,459 'cargo-stylus':90 'cast':104 'cd':216,238,241,253,260,270 'chain':87,120,200,406,441 'check':93,285 'cli':89 'client':404 'client.readcontract':416 'clone':233 'compat':150,498 'compil':58 'connect':432 'const':403,413 'consumpt':315 'contract':21,42,52,66,88,100,135,163,184,188,190,194,245,252,258,412,485,494,512,515 'contractabi':420 'contracts-solid':189,257 'contracts-stylus':183 'core':277 'cover':17 'creat':209,264 'createpubliccli':395,405 'cross':514 'cross-contract':513 'd':43 'dapp':3,9,45,177,215,220 'debug':553 'decis':129 'deeper':525 'default':373 'deploy':24,94,108,289,298,302,330,340,367,451,555 'dev':199 'develop':22,46 'devnod':19,81,197,231,294,336,360,449,549 'docker':83 'docker-bas':82 'encod':509 'endpoint':286,303 'entrypoint':533 'environ':385,480 'evm':73,497 'evm-compat':496 'export':96,311,319,454,462 'export-abi':95,318,461 'fast':128 'first':445 'flow':130 'forg':103,255,325,328,342,466 'foundri':71,102,192,322,540 'friend':127 'frontend':27,112,179,262,314,390,476 'full':426 'fulli':165 'functionnam':421 'fund':297,339,366 'gas':141 'git':201,232 'github.com':235 'github.com/offchainlabs/nitro-devnode.git':234 'guid':6 'guidanc':526 'hardcod':388,491 'hook':430 'http':396,409 'hybrid':157 'import':394,399,478 'init':222,256 'inspect':467 'integr':28 'interact':109,121,442 'interoper':166 'keep':469 'key':308,310,353,355,375,383,489 'layer':48 'layout':172 'load':520 'local':18,77,85,198,230,331,444 'localhost':287,304,348 'locat':474 'lower':140 'macro':532 'mainnet':559 'manag':123 'max':138 'mkdir':211 'model':506 'monorepo':171 'my-arbitrum-dapp':174,212,217 'myfunct':422 'n':225,227 'need':137,147,523 'never':387,490 'new':35,134,248 'next':266 'next-app':265 'next.js':114,181 'nitro':80,196,293,335,359,448,548 'nitro-devnod':79,195,292,334,358,447 'node':78 'note':50,356 'opinion':5 'packag':122,224 'package.json':204 'path':74 'pattern':427,530,546 'perform':139 'pnpm':124,221,263,272 'pnpm-workspace.yaml':203,228 'pre':296,338,365 'pre-fund':295,337,364 'principl':436 'printf':223 'privat':307,309,352,354,374,488 'private-key':306,351 'project':37,169 'prototyp':152 'rapid':151 'react':26,113,180,543 'read':410 'recommend':173 'refer':519 'references/deployment.md':554 'references/frontend-integration.md':424,542 'references/local-devnode.md':370,547 'references/solidity-contracts.md':155,534 'references/stylus-rust-contracts.md':145,527 'references/testing.md':560 'result':414 'rpc':346,483 'rpc-url':345 'run':61 'rust':14,53,143,186,280 'scaffold':170 'script':343 'script/deploy.s.sol':344 'sdk':56,529 'seamless':518 'secret':389,492 'see':144,154,369,423 'setup':20,550 'share':473,500 'ship':361 'skill':4 'skill-arbitrum-dapp-skill' 'smart':51,65 'solid':16,41,67,68,111,153,162,191,193,251,259,321,465,511,535,567 'source-hummusonrails' 'space':504 'specif':538 'stack':47 'standard':72 'start':33,132 'step':206 'storag':505,531 'strategi':562 'stylus':13,39,55,63,92,99,142,160,185,187,244,247,279,284,301,317,458,460,493,528,565 'stylus-sdk':54 'submodul':202 'tanstack/react-query':276 'test':23,107,327,329,443,561 'testnet':453,557 'testnet/mainnet':379 'tool':49,149 'toolchain':101 'topic-agent-skills' 'topic-arbitrum' 'topic-claude-code-skills' 'topic-claude-skills' 'topic-dapp-development' 'topic-ethereum' 'topic-smart-contracts' 'topic-solidity' 'topic-stylus' 'topic-web3' 'transact':435 'transport':408 'typescript':269,393 'url':347,484 'use':12,31,158,290,332,380,438,479 'v0.10':57 'valid':282 'variabl':386,481 'via':384 'viem':30,115,117,274,391,398,439,544 'viem/chains':402 'vm':64 'wagmi':116,275,392,429,545 'wallet':431 'wasm':60 'work':517 'workflow':278,541 'workspac':126,210 'workspace-friend':125 'write':38,434 'x':70","prices":[{"id":"88fc6cfc-f7d6-44b7-b786-9fc929111828","listingId":"6cc9f465-dc08-40b9-9c2a-cbbbe6c6c72b","amountUsd":"0","unit":"free","nativeCurrency":null,"nativeAmount":null,"chain":null,"payTo":null,"paymentMethod":"skill-free","isPrimary":true,"details":{"org":"hummusonrails","category":"arbitrum-dapp-skill","install_from":"skills.sh"},"createdAt":"2026-05-18T13:22:24.258Z"}],"sources":[{"listingId":"6cc9f465-dc08-40b9-9c2a-cbbbe6c6c72b","source":"github","sourceId":"hummusonrails/arbitrum-dapp-skill","sourceUrl":"https://github.com/hummusonrails/arbitrum-dapp-skill","isPrimary":false,"firstSeenAt":"2026-05-18T13:22:24.258Z","lastSeenAt":"2026-05-18T19:14:49.559Z"}],"details":{"listingId":"6cc9f465-dc08-40b9-9c2a-cbbbe6c6c72b","quickStartSnippet":null,"exampleRequest":null,"exampleResponse":null,"schema":null,"openapiUrl":null,"agentsTxtUrl":null,"citations":[],"useCases":[],"bestFor":[],"notFor":[],"kindDetails":{"org":"hummusonrails","slug":"arbitrum-dapp-skill","github":{"repo":"hummusonrails/arbitrum-dapp-skill","stars":6,"topics":["agent-skills","arbitrum","claude-code-skills","claude-skills","dapp-development","ethereum","smart-contracts","solidity","stylus","web3"],"license":"mit","html_url":"https://github.com/hummusonrails/arbitrum-dapp-skill","pushed_at":"2026-02-18T17:01:38Z","description":"Claude Code skill for building dApps on Arbitrum using Stylus (Rust) and/or Solidity","skill_md_sha":"6d653094dc4e95a6ce666bd86cdeb0e209fce221","skill_md_path":"SKILL.md","default_branch":"main","skill_tree_url":"https://github.com/hummusonrails/arbitrum-dapp-skill"},"layout":"root","source":"github","category":"arbitrum-dapp-skill","frontmatter":{"name":"arbitrum-dapp-skill","description":"Opinionated guide for building dApps on Arbitrum using Stylus (Rust) and/or Solidity. Covers local devnode setup, contract development, testing, deployment, and React frontend integration with viem. Use when starting a new Arbitrum project, writing Stylus or Solidity contracts, deploying to Arbitrum, or building a frontend that interacts with Arbitrum contracts."},"skills_sh_url":"https://skills.sh/hummusonrails/arbitrum-dapp-skill"},"updatedAt":"2026-05-18T19:14:49.559Z"}}