Installation Guide
This comprehensive guide covers everything you need to install, configure, and run Music Store on your local machine or production environment.System Requirements
Before installing Music Store, ensure your system meets these requirements:Required Software
- Node.js: Version 18.0.0 or higher (LTS recommended)
- Package Manager: npm 9+, yarn 1.22+, or pnpm 8+
- Git: Latest version for cloning the repository
- Modern Browser: Chrome 90+, Firefox 88+, Safari 14+, or Edge 90+
Recommended Specifications
- RAM: 4GB minimum, 8GB recommended
- Storage: 500MB free space for dependencies
- Display: 1920x1080 or higher for optimal viewing
Music Store uses WebGL for 3D graphics. Ensure your system has GPU acceleration enabled for the best performance.
Installation Steps
Clone the Repository
First, clone the Music Store repository from GitHub:Verify the clone was successful:You should see the project structure with
package.json, src/, and other directories.Install Dependencies
Install all required npm packages. Music Store has been tested with npm, yarn, and pnpm:This will install all dependencies from
package.json:Core Dependencies:[email protected]- React library[email protected]- React DOM renderer[email protected]- Client-side routing@supabase/[email protected]- Supabase client[email protected]- Animation library[email protected]- WebGL graphics[email protected]- Motion animations[email protected]- Mathematical functions
[email protected]- Build tool@vitejs/[email protected]- Vite React plugin[email protected]- CSS framework[email protected]- Code linting[email protected]- CSS autoprefixer
Set Up Supabase Project
Music Store uses Supabase as its backend. Follow these steps to set up your Supabase project:
Create a Supabase Account
- Go to supabase.com
- Sign up for a free account
- Create a new project
- Choose a project name and database password
- Select a region closest to your users
Create Database Tables
Navigate to the SQL Editor in your Supabase dashboard and run this schema:Seed Sample Data (Optional)
Add some sample products to test the application:Configure Environment Variables
Create a Add your Supabase credentials to the This client is imported throughout the app to fetch and manage data.
.env file in the project root directory:.env file:.env
Finding Your Supabase Credentials
- Open your Supabase project dashboard
- Navigate to Settings > API
- Copy the Project URL to
VITE_SUPABASE_URL - Copy the anon public key to
VITE_SUPABASE_KEY
Verify Environment Variables
The Supabase client is configured inbackend/supabaseClient.js:backend/supabaseClient.js
Configure Tailwind CSS (Optional)
Tailwind CSS is pre-configured, but you can customize it:The application uses custom fonts loaded in
tailwind.config.js
index.html:index.html
Start Development Server
Launch the Vite development server:You should see output similar to:The development server features:
- Hot Module Replacement (HMR) - Instant updates without page reload
- Fast Refresh - Preserves component state during edits
- Error Overlay - In-browser error messages
- Optimized Deps - Pre-bundled dependencies for speed
Verify Installation
Confirm that Music Store is working correctly:1. Check the Homepage
Navigate tohttp://localhost:5173 and verify:
- Hero section displays with animated text
- Grainient background renders smoothly
- Navigation bar appears with glassmorphic effect
- No console errors in browser DevTools
2. Test Supabase Connection
Open browser DevTools (F12) and check the Network tab:- Successful request to Supabase API
- Products data loads without errors
- Response status is 200 OK
3. Test Cart Functionality
- Cart icon appears in navigation
- Clicking cart opens the panel
- Adding products updates cart count
- Cart total calculates correctly
4. Test Navigation
- Category links work without page reload
- Product detail pages load
- Browser back/forward buttons work
- URL updates correctly
Build for Production
When you’re ready to deploy, create an optimized production build:dist/ directory with:
- Minified JavaScript bundles
- Optimized CSS files
- Compressed assets
- Static HTML files
Preview Production Build
Test the production build locally:Troubleshooting
Common Issues
Port 5173 already in use
Port 5173 already in use
If port 5173 is occupied, Vite will automatically try the next available port. You can also specify a custom port:
Environment variables not loading
Environment variables not loading
Ensure your
.env file:- Is in the project root directory
- Uses
VITE_prefix for all variables - Has no quotes around values
- Is not in
.gitignoreduring development
Supabase connection errors
Supabase connection errors
Verify:
- Supabase URL is correct (should end in
.supabase.co) - Using the
anonkey, notservice_role - RLS policies are configured correctly
- Project is not paused (free tier limitation)
WebGL not working
WebGL not working
Check:
- GPU acceleration is enabled in browser settings
- Graphics drivers are up to date
- Browser supports WebGL 2.0
- No browser extensions blocking WebGL
Dependencies installation fails
Dependencies installation fails
Try:
Next Steps
Component Documentation
Learn about all available components and how to use them
Supabase Setup
Configure your Supabase database and schema
Styling Guide
Customize colors, fonts, and animations with Tailwind
Deployment
Deploy to Vercel, Netlify, or other platforms
