Build & deployment
Build, verify, preview, package, and deploy the Adminator 4.4 static dashboard.
Last updated October 13, 2026
Build commands
Use Node.js 22.22.2 or newer; the CI matrix covers Node 22 and 24. Install the repository lockfile with npm ci.
npm run check # lint, 77 unit tests, minified build, asset/budget checks
npm run build # unminified production build
npm run release:minified # minified production build
npm run release:unminified # alias for npm run build
npm run build:analyze # dist/bundle-report.html, no automatic browser launch
npm run preview # serve existing dist/ at http://127.0.0.1:3001
Preview serves the existing build directly without recompiling. Use PORT to change its port. npm start serves development with hot reload on port 4000; set HOST=0.0.0.0 explicitly for LAN testing.
Generated assets
All builds write to dist/. The minified release contains 18 HTML pages, the shared entry/runtime/styles, and three lazy widget bundles. JS, CSS, and imported image filenames contain content hashes; use the references in generated HTML.
dist/
index.html, calendar.html, charts.html, ...
runtime.<hash>.js
2026.<hash>.js
style.<hash>.css
vendor-chartjs.<hash>.js
vendor-fullcalendar.<hash>.js + .css
vendor-jsvectormap.<hash>.js + .css
Minified output is approximately 0.94 MB, down 70.5% from v4.3.0 after omitting unused legacy asset copies. This measures all files in dist/, not a single page download. Initial assets remain 128.4 KiB raw / 27.2 KiB gzip. webpack limits minified entry assets to 140 KiB raw and individual assets to 320 KiB; the verification script additionally limits initial gzip assets to 35 KiB.
npm run verify:build verifies every source page is built and every local script, stylesheet, and image reference exists. Imported source assets are emitted automatically; the legacy static folder is no longer copied wholesale.
Deploy to a static host
Deploy the contents of dist/ to Netlify, Vercel, Cloudflare Pages, S3, or another static host. Use npm ci as the install command and npm run release:minified as the build command. Preserve nested asset paths.
Upload content-hashed assets before HTML, retain assets referenced by older cached HTML, then invalidate the updated HTML paths. Cache hashed assets with public, max-age=31536000, immutable; HTML should revalidate. Enable compression at the host/CDN rather than adding a misleading Content-Encoding header to uncompressed files.
Packaging and release workflow
Pushes to master validate lint, tests, the production dependency audit, and the minified build. When the package version is unreleased, CI runs browser checks and creates minified/unminified ZIPs plus a GitHub release. Existing versions skip archive creation. Routine PRs do not need a version bump; bump package.json for an actual release.
ZIP from inside dist/ (zip -r ../static_minified.zip .) rather than flattening paths. The shell reads its displayed version from the package metadata.
npm publish runs npm run check through prepublishOnly. Publishing requires a valid npm login and, where applicable, two-factor verification. The GitHub release and live demo can be updated independently of npm; consult the registry’s latest version before pinning a CDN package.
For a Sass-enabled bundler, import the source stylesheet:
import 'adminator-admin-dashboard/src/assets/styles/2026/index.scss';
For static integrations, copy dist/ and keep its generated references intact. See Testing & workflow and the changelog.