From 82ea9b7d8dc7526641f359ded5d037f9492d7a7f Mon Sep 17 00:00:00 2001 From: Eugen Istoc Date: Fri, 12 Aug 2022 17:31:24 -0400 Subject: [PATCH] fix: remove now-unneeded `@types/tailwindcss` (#514) Co-authored-by: Daniel Roe --- package.json | 1 - src/module.ts | 4 ++-- yarn.lock | 9 +-------- 3 files changed, 3 insertions(+), 11 deletions(-) diff --git a/package.json b/package.json index d57244ac..897c287b 100755 --- a/package.json +++ b/package.json @@ -28,7 +28,6 @@ "dependencies": { "@nuxt/kit": "^3.0.0-rc.5", "@nuxt/postcss8": "^1.1.3", - "@types/tailwindcss": "^3.0.11", "autoprefixer": "^10.4.7", "chalk": "^5.0.1", "clear-module": "^4.1.2", diff --git a/src/module.ts b/src/module.ts index d432a1a1..9644bb60 100644 --- a/src/module.ts +++ b/src/module.ts @@ -134,7 +134,7 @@ export default defineNuxtModule({ // Expose resolved tailwind config as an alias // https://tailwindcss.com/docs/configuration/#referencing-in-javascript if (moduleOptions.exposeConfig) { - const resolveConfig = await import('tailwindcss/resolveConfig.js').then(r => r.default || r) as any + const resolveConfig = await import('tailwindcss/resolveConfig.js').then(r => r.default || r) const resolvedConfig = resolveConfig(tailwindConfig) const template = addTemplate({ filename: 'tailwind.config.mjs', @@ -142,7 +142,7 @@ export default defineNuxtModule({ }) addTemplate({ filename: 'tailwind.config.d.ts', - getContents: () => 'declare const config: import("tailwindcss/tailwind-config").TailwindConfig\nexport { config as default }', + getContents: () => 'declare const config: import("tailwindcss").Config\nexport { config as default }', write: true }) nuxt.options.alias['#tailwind-config'] = template.dst diff --git a/yarn.lock b/yarn.lock index d023c3bb..f8988b0f 100644 --- a/yarn.lock +++ b/yarn.lock @@ -908,13 +908,6 @@ dependencies: "@types/node" "*" -"@types/tailwindcss@^3.0.11": - version "3.1.0" - resolved "https://registry.yarnpkg.com/@types/tailwindcss/-/tailwindcss-3.1.0.tgz#1185e4b3437c6e0f19d6cc8cd42738a94fd7b64f" - integrity sha512-JxPzrm609hzvF4nmOI3StLjbBEP3WWQxDDJESqR1nh94h7gyyy3XSl0hn5RBMJ9mPudlLjtaXs5YEBtLw7CnPA== - dependencies: - tailwindcss "*" - "@types/tough-cookie@*": version "4.0.2" resolved "https://registry.yarnpkg.com/@types/tough-cookie/-/tough-cookie-4.0.2.tgz#6286b4c7228d58ab7866d19716f3696e03a09397" @@ -7302,7 +7295,7 @@ tailwind-config-viewer@^1.7.1: portfinder "^1.0.26" replace-in-file "^6.1.0" -tailwindcss@*, tailwindcss@^3.1.6: +tailwindcss@^3.1.6: version "3.1.6" resolved "https://registry.yarnpkg.com/tailwindcss/-/tailwindcss-3.1.6.tgz#bcb719357776c39e6376a8d84e9834b2b19a49f1" integrity sha512-7skAOY56erZAFQssT1xkpk+kWt2NrO45kORlxFPXUt3CiGsVPhH1smuH5XoDH6sGPXLyBv+zgCKA2HWBsgCytg==