MyGit
🚩收到GitHub仓库的更新通知

windicss/vite-plugin-windicss

Fork: 66 Star: 849 (更新于 2024-05-03 16:48:40)

license: MIT

Language: TypeScript .

🍃 Windi CSS for Vite ⚡️

最后发布版本: v1.9.3 ( 2023-12-25 23:35:14)

GitHub网址

✨免费申请网站SSL证书,支持多域名和泛域名,点击查看

⚠️ Windi CSS is Sunsetting ⚠️
We are sunsetting Windi CSS and we recommend new projects to seek for alternatives. Read the full blog post.


vite-plugin-windicss

Windi CSS for Vite, it's fast! ⚡️

Features

  • ⚡️ It's FAST - 20~100x times faster than Tailwind on Vite
  • 🧩 On-demand CSS utilities (Fully compatible with Tailwind CSS v2)
  • 📦 On-demand native elements style reseting (preflight)
  • 🔥 Hot module replacement (HMR)
  • 🍃 Load configurations from tailwind.config.js
  • 🤝 Framework-agnostic - Vue, React, Svelte and vanilla!
  • 📄 CSS @apply / @screen directives transforms (also works for Vue SFC's <style>)
  • 🎳 Support Variant Groups - e.g. bg-gray-200 hover:(bg-gray-100 text-red-300)
  • 😎 "Design in Devtools" - if you work this way in the traditional Tailwind, no reason we can't!

Documentation

Read the documentation for more details.

New Features in v3.0

Attributify Mode

Enabled it by

// windi.config.ts
export default {
  attributify: true,
}

And use them as you would like:

<button 
  bg="blue-400 hover:blue-500 dark:blue-500 dark:hover:blue-600"
  text="sm white"
  font="mono light"
  p="y-2 x-4"
  border="2 rounded blue-200"
>
  Button
</button>

Prefix

If you are concerned about naming confliction, you can add custom prefix to attributify mode by:

// windi.config.ts
export default {
  attributify: {
    prefix: 'w:',
  },
}
<button 
  w:bg="blue-400 hover:blue-500 dark:blue-500 dark:hover:blue-600"
  w:text="sm white"
  w:font="mono light"
  w:p="y-2 x-4"
  w:border="2 rounded blue-200"
>
  Button
</button>

Alias Config

// windi.config.ts
export default {
  alias: {
    'hstack': 'flex items-center',
    'vstack': 'flex flex-col',
    'icon': 'w-6 h-6 fill-current',
    'app': 'text-red',
    'app-border': 'border-gray-200 dark:border-dark-300',
  },
}

Sponsors

License

MIT License © 2021 Anthony Fu

最近版本更新:(数据更新于 2024-05-07 03:17:31)

2023-12-25 23:35:14 v1.9.3

2023-11-21 18:28:21 v1.9.2

2023-08-12 22:18:01 v1.9.1

2023-05-09 18:32:44 v1.9.0

2023-05-09 18:15:20 v1.8.11

2022-12-13 17:29:35 v1.8.10

2022-12-13 04:31:43 v1.8.9

2022-09-09 22:24:51 v1.8.8

2022-07-14 17:37:49 v1.8.7

2022-06-30 15:03:53 v1.8.6

windicss/vite-plugin-windicss同语言 TypeScript最近更新仓库

2024-05-19 21:28:39 siyuan-note/siyuan

2024-05-19 02:57:13 bepass-org/oblivion-desktop

2024-05-18 20:59:00 FuelLabs/fuels-ts

2024-05-18 10:05:52 johnlindquist/kit

2024-05-18 04:16:53 payloadcms/payload

2024-05-17 17:04:00 steven-tey/novel