Why donate
API Explorer
Upgrade Guide
Creating a New Project
The /quasar.config File
Convert q/app-webpack Project
Browser Compatibility
TypeScript Support
Directory Structure
Commands List
CSS Preprocessors
Page Routing with VueRouter
Lazy Loading - Code Splitting
Handling Assets
Boot Files
Prefetch Feature
API Proxying
Handling Vite
Handling import.meta.env
State Management with Pinia
Lint and Format Code
Testing & Auditing
Developing Mobile Apps
Ajax Requests
Opening Dev Server To Public
Quasar CLI with Vite - @quasar/app-vite v3
SSG Build Commands

Warning! Beta Stage

The Quasar SSG Mode is currently in the “beta” stage. Based on the community feedback, the API may change in the future, so check the release notes each time you upgrade “@quasar/app-vite”.

Developing

quasar dev -m ssg

# ..or the longer form:
quasar dev --mode ssg

The development server renders normal SSG routes through the SSR pipeline. Routes matched by ssg.clientSideRenderingRoutes are rendered on the client. The /src-ssg/ssg-renderer file is used only during a production build, so the development server does not write static HTML files.

Building for Production

quasar build -m ssg

# ..or the longer form:
quasar build --mode ssg

The default output directory is dist/ssg. The build fails if getSsgPages() returns no pages or if two page definitions try to write the same file.

TIP

Should you want to change the default error handling behaviour of the SSG render process (fail on first error), and instead you want to go through all SSG pages then error out, or just warn but not fail, or ignore the errors completely, you can use the quasar.config > ssg > onSsgRendererError.

If you want a production build with debugging enabled:

quasar build -m ssg -d

# ..or the longer form
quasar build -m ssg --debug