Skip to content

Commit

Permalink
chore: unocss to tailwindcss
Browse files Browse the repository at this point in the history
  • Loading branch information
productdevbook committed Jul 9, 2023
1 parent 6addaca commit 1cee864
Show file tree
Hide file tree
Showing 12 changed files with 584 additions and 130 deletions.
5 changes: 1 addition & 4 deletions playground/nuxt3/nuxt.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import { resolve } from 'pathe'
// https://nuxt.com/docs/api/configuration/nuxt-config
export default defineNuxtConfig({
modules: [
'@unocss/nuxt',
'@nuxtjs/tailwindcss',
async () => {
const components = globbySync('../../packages/components/**/src/stories/*.@(vue)')
if (components.length > 0) {
Expand All @@ -16,7 +16,4 @@ export default defineNuxtConfig({
}
},
],
css: [
'@unocss/reset/tailwind.css',
],
})
2 changes: 1 addition & 1 deletion playground/nuxt3/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,8 @@
"@oku-ui/separator": "workspace:^"
},
"devDependencies": {
"@nuxtjs/tailwindcss": "^6.8.0",
"@types/node": "^18.16.19",
"@unocss/nuxt": "^0.53.5",
"nuxt": "^3.6.2"
}
}
10 changes: 10 additions & 0 deletions playground/nuxt3/tailwind.config.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
/** @type {import('tailwindcss').Config} */
export default {
content: [
'../../packages/**/src/**/*.vue',
],
theme: {
extend: {},
},
plugins: [],
}
29 changes: 0 additions & 29 deletions playground/nuxt3/uno.config.ts

This file was deleted.

1 change: 0 additions & 1 deletion playground/vue3/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,6 @@
"devDependencies": {
"@vitejs/plugin-vue": "^4.2.3",
"typescript": "^5.1.6",
"unocss": "^0.53.5",
"unplugin-auto-import": "^0.16.6",
"unplugin-vue-components": "^0.25.1",
"vite": "^4.4.2",
Expand Down
8 changes: 8 additions & 0 deletions playground/vue3/postcss.config.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
export default {
plugins: {
'postcss-import': {},
'tailwindcss/nesting': {},
'tailwindcss': {},
'autoprefixer': {},
},
}
2 changes: 0 additions & 2 deletions playground/vue3/src/main.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
import '@unocss/reset/tailwind.css'
import 'virtual:uno.css'
import { createRouter, createWebHistory } from 'vue-router'
import { createApp } from 'vue'
import App from './App.vue'
Expand Down
4 changes: 4 additions & 0 deletions playground/vue3/src/style.css
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
@tailwind base;
@tailwind components;
@tailwind utilities;

body {
@apply p-4
}
Expand Down
12 changes: 12 additions & 0 deletions playground/vue3/tailwind.config.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
/** @type {import('tailwindcss').Config} */
export default {
content: [
'./index.html',
'./src/**/*.{js,ts,jsx,tsx,vue}',
'../../packages/**/src/**/*.vue',
],
theme: {
extend: {},
},
plugins: [],
}
29 changes: 0 additions & 29 deletions playground/vue3/uno.config.ts

This file was deleted.

2 changes: 0 additions & 2 deletions playground/vue3/vite.config.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
import { resolve } from 'node:path'
import { defineConfig } from 'vite'
import vue from '@vitejs/plugin-vue'
import UnoCSS from 'unocss/vite'
import Pages from 'vite-plugin-pages'

import Components from 'unplugin-vue-components/vite'
Expand All @@ -11,7 +10,6 @@ import AutoImport from 'unplugin-auto-import/vite'
export default defineConfig({
plugins: [
vue(),
UnoCSS(),
Pages(),
Components({
dirs: [
Expand Down

0 comments on commit 1cee864

Please sign in to comment.