šŸš€ Installation #

This guide will walk you through setting up Admindek on your local development environment.

System Requirements #

Before you begin, ensure your system meets these requirements:

Required #

  • Node.js: Version 20.19 or higher (required by Vite 8)
  • npm: Version 10 or higher (comes with Node.js 20+)
  • Git: For version control and updates
  • VS Code: With extensions for better development experience
  • pnpm: The template uses pnpm workspaces internally — install with npm install -g pnpm

Quick Installation #

  1. Download the Admindek package
  2. Extract the ZIP file to your desired location
  3. Open terminal in the extracted folder
  4. Install dependencies:
    npm install
  5. Start development server:
    npm start
  6. Open your browser to http://localhost:4173
# Clone the repository
git clone <repository-url>
cd admindek-html
 
# Install dependencies
npm install
 
# Start development server
npm start

Verify Installation #

After installation, you should see:

  1. Terminal output indicating successful build:

    šŸ”„ Starting development server with automatic rebuild...
    āœ… Build completed successfully!
    šŸ‘€ Watching for changes in src/html/ and src/assets/scss/
  2. Browser opening automatically to http://localhost:4173

  3. Analytics Dashboard displaying with sample data and charts

Project Structure #

After installation, your project structure will look like this:

admindek-html/
ā”œā”€ā”€ src/                    # Source files
│   ā”œā”€ā”€ html/              # HTML templates
│   ā”œā”€ā”€ assets/            # SCSS, JS, images
│   └── entries/           # Entry points
ā”œā”€ā”€ dist/                  # Built files (auto-generated)
ā”œā”€ā”€ docs/                  # Documentation
ā”œā”€ā”€ plugins/               # Custom Vite plugins
ā”œā”€ā”€ package.json           # Dependencies and scripts
ā”œā”€ā”€ vite.config.js         # Build configuration
└── README.md             # Project information

Development Commands #

Once installed, you can use these commands:

CommandDescriptionWhen to Use
npm run devStart the Vite dev server with HMRDaily development
npm run buildBuild for productionBefore deployment
npm run previewPreview the production buildTesting builds
npm run formatFormat code with PrettierCode cleanup

Development Workflow #

Standard Development Process #

  1. Start the dev server:

    npm run dev
  2. Open the URL printed in your terminal (typically http://localhost:5173)

  3. Edit files in the src/ directory

  4. See changes instantly — Vite HMR reloads the page automatically when you save

Hot Module Replacement #

As of v3.4, Admindek uses Vite's native HMR for development. When you save a file, the browser updates automatically — no manual refresh required.

For production builds, run npm run build to generate the optimized output in dist/, then npm run preview to test it locally.

Troubleshooting Installation #

Common Issues #

Node.js Version Error #

Error: Node.js version 14.x is not supported

Solution: Upgrade to Node.js 16+ from nodejs.org

Permission Errors (Windows) #

EACCES: permission denied

Solution: Run terminal as Administrator or use:

npm install --no-optional

Port Already in Use #

Port 4173 is already in use

Solution: The system will automatically find an available port, or specify one:

npm run preview -- --port 3001

Build Errors #

Module not found or build failed

Solution:

  1. Clear node_modules: rm -rf node_modules package-lock.json
  2. Reinstall: npm install
  3. Try again: npm start

Getting Help #

If you encounter issues not covered here:

  1. Check our Troubleshooting Guide
  2. Verify your Node.js version: node --version
  3. Clear browser cache and try again
  4. Contact support at contact@dashboardpack.com

Next Steps #

šŸŽ‰ Installation Complete! Your development environment is ready.

What's next?


Having trouble? Check our Common Issues guide or contact support.