Skip to content

JiangWeixian/vite-plugin-styled-windicss

Repository files navigation

vite-plugin-styled-windicss

windicss + styled-components = 🥰

npm GitHub

install

yarn add vite-plugin-styled-windicss -D

features

  • ✨ transform @apply for styled-components

usage

require vite-plugin-windicss

in vite.config.ts

export default defineConfig({
  plugins: [reactRefresh(), Windicss(), StyledWindicss()],
})

in any.tsx, will

// input
const Wrapped = styled.div`
  @apply m-0 p-0 w-100vw h-100vh overflow-hidden;
`
// output
const Wrapped = styled.div`
  color: red;
  margin: 0px;
  overflow: hidden;
  padding: 0px;
  width: 100vw;
`

About

styled-components with windicss in vite

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors 3

  •  
  •  
  •