/nuxt-style-extractor

Extracts the style of the page as an external css when rendered on the server side | 提取服务端渲染时页面的 style 为外部 css

Primary LanguageTypeScript

nuxt-style-extractor

Extracts the style of the page as an external css when rendered on the server side


README 🦉

简体中文 | English


Motivation

Faster rendering and more readable seo


Features

  • 🚠  Optimal Caching
  • ⛰  Supports all rendering modes, spa, ssg, ssr and ssr with pre-rendering.
  • 🌲  Intelligent minification extraction, removing unused styles from the page, merging duplicate styles

Quick Setup

Install the module

npm i nuxt-style-extractor

Setup Module

// nuxt.config.ts
export default defineNuxtConfig({
  modules: ["nuxt-style-extractor"],
});

That's all. Everything's automatic.