❓ Troubleshooting #
This section helps you diagnose and resolve common issues you might encounter while working with Admindek.
🎯 How to Use This Guide #
This troubleshooting section is organized by:
- Problem type - Installation, build, runtime, or deployment issues
- Symptom - What you're seeing that indicates a problem
- Solution - Step-by-step resolution instructions
- Prevention - How to avoid the issue in the future
🔍 Quick Diagnosis #
Issue Categories #
| Symptom | Likely Category | Quick Fix |
|---|---|---|
| Won't install/build | Common Issues | Check Node.js version |
| Styles not loading | Common Issues | Clear browser cache |
| Charts not rendering | Common Issues | Check console errors |
| Slow page loads | Common Issues | Optimize bundle size |
| Layout broken | Common Issues | Verify CSS imports |
Emergency Fixes #
# Nuclear option - complete reset
rm -rf node_modules package-lock.json dist
npm install
npm run build
npm run preview📚 Troubleshooting Sections #
🔧 Common Issues #
Frequently encountered problems and their solutions.
Covers:
- Installation problems
- Configuration issues
- Template rendering errors
- Asset loading failures
- Navigation problems
🛠️ Diagnostic Tools #
Browser Developer Tools #
Console Tab #
// Check for JavaScript errors
console.error() // Red messages indicate problems
console.warn() // Yellow messages show warnings
// Debug chart initialization
window.ApexCharts // Should be available if charts loaded
document.querySelector('#chart-id') // Check if chart container existsNetwork Tab #
Status Codes to Watch:
├── 404: Missing files (check file paths)
├── 500: Server errors (check backend)
├── 304: Cached (good for performance)
└── 200: Successful loadingPerformance Tab #
Key Metrics:
├── First Contentful Paint (FCP) < 1.5s
├── Largest Contentful Paint (LCP) < 2.5s
├── Cumulative Layout Shift (CLS) < 0.1
└── First Input Delay (FID) < 100msCommand Line Diagnostics #
Environment Check #
# Verify versions
node --version # Should be 16+
npm --version # Should be 7+
git --version # Should be 2.0+
# Check project status
npm list # Show installed packages
npm audit # Check for vulnerabilities
npm outdated # Show package updatesBuild Analysis #
# Analyze bundle size
npm run build -- --analyze
# Check build output
ls -la dist/ # Verify files generated
du -sh dist/ # Check total size
# Test production build
npm run preview # Preview production build🔍 Problem-Solving Methodology #
Step 1: Identify the Problem #
-
What were you trying to do?
- Installing the template
- Building for production
- Customizing components
- Deploying to server
-
What did you expect to happen?
- Successful installation
- Working dashboard
- Custom styling applied
- Live website
-
What actually happened?
- Error messages
- Blank screens
- Incorrect styling
- Build failures
Step 2: Gather Information #
# Collect system information
echo "Node: $(node --version)"
echo "NPM: $(npm --version)"
echo "OS: $(uname -a)"
echo "Date: $(date)"
# Check project status
npm list --depth=0
git status
git log --oneline -5Step 3: Isolate the Issue #
Minimal Reproduction #
- Start with a fresh installation
- Apply changes one at a time
- Test after each change
- Identify the breaking change
Environment Testing #
# Test in different environments
npm run dev # Development mode
npm run build # Development build
npm run build # Production build
# Test in different browsers
# Chrome, Firefox, Safari, EdgeStep 4: Apply Solutions #
Progressive Fixes #
- Simple fixes first - Clear cache, restart server
- Configuration fixes - Check settings, update variables
- Code fixes - Review custom code, fix syntax errors
- Nuclear option - Complete reinstall
🔄 Common Resolution Patterns #
Cache-Related Issues #
# Clear all caches
rm -rf node_modules/.cache
rm -rf dist
npm run clean-duplicates
# Clear browser cache
# Chrome: Ctrl+Shift+R (hard refresh)
# Firefox: Ctrl+F5
# Safari: Cmd+Option+RPermission Issues (Windows) #
# Run as Administrator
npm config set scripts-prepend-node-path true
# Alternative: Use Yarn
npm install -g yarn
yarn install
yarn buildPath-Related Issues #
# Check for spaces in paths
pwd | grep " " # Should return nothing
# Use absolute paths for testing
npm run build -- --base="/"📊 Error Code Reference #
Common Error Codes #
| Error | Meaning | Solution |
|---|---|---|
ENOENT | File not found | Check file paths |
EACCES | Permission denied | Fix file permissions |
EADDRINUSE | Port in use | Change port or kill process |
MODULE_NOT_FOUND | Missing dependency | Run npm install |
ESYNTAX | Syntax error | Check code syntax |
Vite-Specific Errors #
# Vite error patterns
"[vite] Internal server error" # Check configuration
"Failed to resolve import" # Check import paths
"Cannot read property" # Check variable names
"Unexpected token" # Check syntax🧪 Testing Procedures #
Quick Health Check #
# 5-minute health check
npm install # Dependencies ok?
npm run build # Build succeeds?
npm run preview # Preview works?
# Visit http://localhost:4173 # Site loads?Comprehensive Testing #
# Full testing procedure
npm run format # Code formatted?
npm run clean-duplicates # No duplicate files?
npm run build # Production build ok?
npm run preview # Production preview ok?
# Manual testing
# ✓ Homepage loads
# ✓ Navigation works
# ✓ Charts render
# ✓ Forms function
# ✓ Mobile responsive📞 Getting Additional Help #
Before Contacting Support #
- Search existing issues - Check documentation first
- Gather information - Error messages, system details
- Create reproduction - Minimal example that shows the problem
- Document steps - What you tried, what didn't work
What to Include in Support Requests #
Subject: [Admindek] Brief description of issue
Environment:
- Node.js version: X.X.X
- NPM version: X.X.X
- Operating System: Windows/Mac/Linux
- Browser: Chrome/Firefox/Safari/Edge
Problem Description:
- What you were trying to do
- What you expected to happen
- What actually happened
- Error messages (full text)
Steps to Reproduce:
1. Step one
2. Step two
3. Step three
Additional Context:
- Recent changes made
- Screenshots if helpful
- Relevant configuration filesSupport Channels #
- Email: contact@dashboardpack.com
- Documentation: This troubleshooting guide
- Community: Check for user forums or GitHub discussions
🎯 Prevention Strategies #
Best Practices #
- Keep dependencies updated - Regular
npm update - Test before deploying - Always verify builds work
- Document customizations - Track changes you make
- Use version control - Git commit frequently
- Backup working versions - Before major changes
Monitoring Tools #
// Add error tracking to production
window.addEventListener('error', (event) => {
console.error('Global error:', event.error);
// Send to error tracking service
});
// Performance monitoring
window.addEventListener('load', () => {
const loadTime = performance.timing.loadEventEnd - performance.timing.navigationStart;
console.log('Page load time:', loadTime);
});🔍 Quick Reference #
Most Common Issues:
Can't find your issue? Use the search function or contact support with detailed information about your problem.