Overview:
The Static Site Generator App Extension for Quasar v2 is a Quasar App Extension designed to generate static sites using the JAMstack architecture. It supports Vite since v4.4.0 and was created to fulfill a feature request from the Quasar community. The extension provides various features for optimizing and improving the development experience of static site generation with Quasar.
Features:
- Add scripts into package.json: Extends the package.json file by adding scripts for easier management and execution of the extension.
- Add auto-completion of ssg property: Augments the configure() helper from Quasar wrappers to provide a better IDE autocomplete experience when using the ssg property of the quasar.config.js file.
- Inline critical CSS and async load the rest: Uses Beastcss to inline critical CSS and asynchronously load the remaining CSS for each generated page.
- Inline CSS from Vue SFC <style> blocks: Inlines CSS from Vue Single-File Component (SFC) <style> blocks.
Installation:
To install the Static Site Generator App Extension for Quasar v2, run the following command in your Quasar project:
npm install @quasar/ssg
Once the installation is complete, interactive prompts will guide you through the setup process.
Summary:
The Static Site Generator App Extension for Quasar v2 is a powerful tool for generating static sites with Quasar. It provides features such as adding scripts to package.json, auto-completion of ssg property, inline critical CSS, and inline CSS from Vue SFC <style> blocks. With these features, developers can optimize their static site generation workflow and improve the performance of their sites.