Development Environment
Universal Prerequisites
Part 1: Universal Setup (Both Paradigms)
Step 1: Install Node.js
macOS
# Using Homebrew
brew install node
# Verify installation
node --version # Should be v18.0.0 or higher
npm --versionWindows
Linux (Ubuntu/Debian)
Step 2: Install TypeScript
Step 3: Set Up Your IDE
VS Code Settings
Step 4: Install BSV SDK
Step 5: Configure TypeScript
Step 6: Set Up Git (Recommended)
Part 2A: Backend/Service Development Setup
Backend Project Structure
Install Backend Dependencies
Environment Variables (Backend)
Backend Test File
Backend NPM Scripts
Test Backend Setup
Part 2B: Frontend/dApp Development Setup
Frontend Project Structure (React Example)
Install Frontend Dependencies
Frontend Test Component
Update App.tsx
Frontend NPM Scripts
Test Frontend Setup
MetaNet Desktop Wallet Installation (BSV Desktop)
Part 3: Testing Your Setup
Backend Test
Frontend Test
Additional Tools
Block Explorers
Getting Testnet BSV
API Documentation
Environment Variables Best Practices
Backend (.env)
Frontend (.env)
Troubleshooting
"Cannot find module '@bsv/sdk'"
"WalletClient connection failed"
TypeScript Errors
Permission Errors (Linux/macOS)
Port Already in Use
Verification Checklist
Backend Development Ready
Frontend Development Ready
Next Steps
Related Resources
Official Documentation
Tools
Community
Last updated
