@tezignlab/vite-plugin-css-string
v0.1.0
Published
A Vite plugin that extracts your css assets into a string at build time.
Downloads
7
Keywords
Readme
@tezignlab/vite-plugin-css-string
A Vite plugin that extracts your css assets into a string at build time.
Getting started
Install
npm install --save-dev @tezignlab/vite-plugin-css-string
Vite config
import { defineConfig } from "vite";
import cssString from "@tezignlab/vite-plugin-css-string";
export default defineConfig({
plugins: [cssString()],
});
Code
In your code, you can import the css string like this:
import cssString from "virtual:css-string";
console.log(cssString);