From 7d778049d0d63b175789426eb39198bc6fe4354e Mon Sep 17 00:00:00 2001 From: Dominic Martinez <33702823+dominicm00@users.noreply.github.com> Date: Mon, 10 May 2021 20:02:09 -0400 Subject: [PATCH 1/2] mark tailwindcss as a peer dependency This plugin uses tailwindcss internally, but marks it only as a dev dependency rather than a peer dependency, causing errors/undefined behavior in monorepos and Yarn PNP. Correctly adding tailwind as a peer dependency allows for correct resolution to occur while still referencing the *user's* tailwind and not an internal version. Other official plugins have already corrected this: see tailwindlabs/tailwindcss-forms@8a8671b This pull request is identical to https://github.com/tailwindlabs/tailwindcss-line-clamp/pull/6. Both other official plugins (forms, typography) already correctly use peer dependencies. --- package.json | 3 +++ 1 file changed, 3 insertions(+) diff --git a/package.json b/package.json index e7e8f84..5dcd467 100644 --- a/package.json +++ b/package.json @@ -15,6 +15,9 @@ }, "scripts": { "prepublishOnly": "node scripts/build.js" + }, + "peerDependencies": { + "tailwindcss": "^2.0.0" }, "devDependencies": { "autoprefixer": "10", From bb844fe6d20a5eefd4c0b82b35cc753359169ba0 Mon Sep 17 00:00:00 2001 From: Adam Wathan Date: Mon, 24 May 2021 12:37:10 -0400 Subject: [PATCH 2/2] Update package.json --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index 5dcd467..eb65620 100644 --- a/package.json +++ b/package.json @@ -17,7 +17,7 @@ "prepublishOnly": "node scripts/build.js" }, "peerDependencies": { - "tailwindcss": "^2.0.0" + "tailwindcss": ">=2.0.0" }, "devDependencies": { "autoprefixer": "10",