Skip to content

Commit

Permalink
Revert "perf: parallelise all async calls (#679)"
Browse files Browse the repository at this point in the history
This reverts commit 5502765.
  • Loading branch information
atinux committed Jun 13, 2023
1 parent 5a877b9 commit 69232a3
Show file tree
Hide file tree
Showing 12 changed files with 349 additions and 369 deletions.
4 changes: 0 additions & 4 deletions docs/content/2.tailwind/1.config.md
Original file line number Diff line number Diff line change
Expand Up @@ -125,10 +125,6 @@ This config has less priority over the [tailwind.config.js](#tailwindconfigjs) f
This is an advanced usage section and intended primarily for Nuxt modules authors.
::

#### `tailwindcss:loadConfig`

Passes any Tailwind configuration read by the module for each (extended) [layer](https://nuxt.com/docs/getting-started/layers)/[path](/getting-started/options#configpath) before merging all of them.

#### `tailwindcss:config`

Passes the resolved vanilla configuration read from all layers and paths with merging using [defu](https://github.com/unjs/defu).
Expand Down
5 changes: 0 additions & 5 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,11 +4,6 @@
"description": "TailwindCSS module for Nuxt",
"repository": "nuxt-modules/tailwindcss",
"license": "MIT",
"configKey": "tailwindcss",
"compatibility": {
"nuxt": "^2.9.0 || ^3.0.0-rc.1",
"bridge": true
},
"exports": {
".": {
"require": "./dist/module.cjs",
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
const colors = require('tailwindcss/colors')
import colors from 'tailwindcss/colors'

module.exports = {
export default {
theme: {
extend: {
colors: {
Expand Down
4 changes: 2 additions & 2 deletions src/vite-hmr.ts → src/hmr.ts
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
import { isAbsolute, resolve } from 'pathe'
import type { Plugin as VitePlugin } from 'vite'
import type { TWConfig } from './types'
import type { Config } from 'tailwindcss'
import micromatch from 'micromatch'

export default function (tailwindConfig: Partial<TWConfig> = {}, rootDir: string, cssPath: string): VitePlugin {
export default function (tailwindConfig: Partial<Config> = {}, rootDir: string, cssPath: string): VitePlugin {
const resolvedContent = ((Array.isArray(tailwindConfig.content) ? tailwindConfig.content : tailwindConfig.content?.files || []).filter(f => typeof f === 'string') as Array<string>).map(f => !isAbsolute(f) ? resolve(rootDir, f) : f)

return {
Expand Down
Loading

0 comments on commit 69232a3

Please sign in to comment.