Local Build and Preview

Purpose

Verify production-like output locally before publishing to a hosting platform.

Commands

Build output:

npm run build

Preview with Shevky dev command:

npm run dev

Or preview static output directly with any static server:

npx serve dist

Validation Checklist

  • Open the homepage and at least one content page.
  • Confirm CSS and JS bundles load without 404 errors.
  • Check generated support files exist: dist/robots.txt, dist/sitemap.xml, dist/feed.xml.
  • Verify canonical URLs in the HTML source match expected values.

Common Issues

IssueFix
Port conflict on 3000Stop conflicting process or use npx serve dist -l 8080
Missing CSS/JS bundlesVerify src/css/app.css and src/js/app.js exist and plugins are listed
Stale contentBuild clears dist/ automatically; delete manually if needed

Related