vite-plugin-theme-style

1.1.2 • Public • Published

vite-plugin-theme-style

Vite plugin to load theme style

install

npm i vite-plugin-theme-style -D 

# yarn 
yarn add vite-plugin-theme-style -D

# pnpm 
pnpm add vite-plugin-theme-style -D

usage

// vite.config.js / vite.config.ts
import ViteTheme from 'vite-plugin-theme-style'

export default {
  plugins: [
    ViteTheme()
  ]
}

example

input

<style lang="scss" theme="theme-custom" scoped>
.home-text {
    background: green;
}
</style>

output

.theme-custom .home-text[data-v-a763a6ae]{
    background: green;
}

Package Sidebar

Install

npm i vite-plugin-theme-style

Weekly Downloads

1

Version

1.1.2

License

ISC

Unpacked Size

3.62 kB

Total Files

9

Last publish

Collaborators

  • yt540951254