Development Guide
This comprehensive guide covers everything you need to know to develop themes and components for Weaverse Hydrogen storefronts.Prerequisites
Before you start developing with Weaverse, ensure you have:- Node.js 18+ installed
- Familiarity with React and TypeScript
- Basic knowledge of Shopify Hydrogen
- Understanding of Tailwind CSS (recommended)
Development Workflow
Environment Setup
Configure your development environment, environment variables, and tools.
Creating Components
Learn how to build Weaverse components with proper schemas and TypeScript support.
Input Settings
Master the configuration system that lets merchants customize your components.
Data Fetching
Implement server-side data loading for sections with Shopify API integration.
Quick Start
Get your development environment up and running in minutes:1
Clone or Create Project
Use the Weaverse CLI to create a new theme:Or clone an existing theme repository:
2
Install Dependencies
3
Configure Environment
Create a
.env
file with your Weaverse and Shopify credentials:4
Start Development Server
http://localhost:3456
Development Commands
Core Development
Code Quality
Testing
Quick Start Checklist
- Set up your development environment
- Create your first component with schema
- Add input settings for customization
- Test in Weaverse Studio
- Implement proper TypeScript types
- Add error boundaries and loading states
Best Practices
- Performance: Keep components lightweight and optimize images
- Accessibility: Follow WCAG guidelines and use semantic HTML
- Mobile-First: Design responsive components from the start
- Schema Design: Create intuitive settings that merchants will understand
- Error Handling: Gracefully handle missing data and API failures
Development Tools
Weaverse CLI
Command line interface for creating and managing themes
Weaverse SDKs
TypeScript SDKs for building components and integrations
Weaverse MCP
AI assistant integration for enhanced development workflow
Troubleshooting
Port 3456 Already in Use
Port 3456 Already in Use
Environment Variables Not Working
Environment Variables Not Working
- Ensure
.env
file is in the project root (same level aspackage.json
) - Check variable names are exactly correct (case-sensitive)
- Restart development server after any
.env
changes - Verify no spaces around the
=
sign in environment variables
Studio Preview Not Loading
Studio Preview Not Loading
- Verify development server is running on port 3456
- Check that
http://localhost:3456
loads in your browser - Ensure no firewall is blocking port 3456
- Try refreshing the Studio page
Next Steps
Once you’ve mastered the basics:- Explore Advanced Features
- Learn about Styling & Theming
- Study the API Reference
- Join the Developer Community