Skip to main content

Build

Skill for building prediction market frontends — React components, wallet integration, and UI patterns using the Context React SDK.
Claude Code: /context:build · Codex: $context-build · API/Cursor/ChatGPT: Load full.md as system prompt

What it covers

DomainReact hooksDescription
Provider setupContextProviderInitialize SDK with wagmi wallet connection
Market displayuseMarkets, useMarket, useOrderbook, useQuotesLive market data components
Trading UIuseCreateOrder, useMarketOrder, useCancelOrderOrder forms and management
Portfolio viewsusePositions, useBalance, useClaimable, usePortfolioStatsPosition and balance display
Wallet integrationuseAccountStatus, useSetupAccount, useDepositAccount onboarding flows
Query managementcontextKeys, TanStack Query patternsCache invalidation and optimistic updates

Prerequisites

  • Context MCP server (optional)
  • Familiarity with React, wagmi, and TanStack Query

Installation

# 1. Clone the skills repository
git clone https://github.com/contextwtf/context-skills.git

# 2. Install the build skill
cd context-skills && ./install.sh build

# 3. Add the Context MCP server (optional, for tool access)
claude mcp add context-markets -- npx @contextwtf/mcp

Example prompts

  • “Build a market card component showing live bid/ask quotes”
  • “Create an order form with price and size inputs for a specific market”
  • “Build a portfolio dashboard showing all active positions”
  • “Add wallet connection with automatic account setup flow”
  • “Create a real-time orderbook visualization component”
  • “Build a market search page with status and category filters”

Composite workflows

Trading app

Complete trading interface: market list, market detail, order form, portfolio view. Uses market query hooks, order mutations, and portfolio hooks.

Market dashboard

Search and filter markets, display live prices, show volume and activity charts. Uses market hooks with polling intervals.

Prediction market widget

Embeddable single-market component with buy/sell buttons. Uses useMarket, useQuotes, and order mutation hooks.

What’s included

FileDescription
SKILL.mdEntry point — React patterns, hook overview, provider setup
prompts/openai.developer.mdOpenAI-formatted system prompt
prompts/claude.system.mdClaude-formatted system prompt
prompts/full.mdUniversal format
references/react-hooks.mdFull hook API reference
references/provider-setup.mdContextProvider and wagmi configuration
references/query-patterns.mdTanStack Query best practices
references/wagmi-integration.mdWallet connection patterns