mark tailwindcss as a peerDependency #50
Merged
+4
−1
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Internally we are using tailwindcss/plugin, but we don't mark it as a
peerDependency or a normal dependency in our package.json. This means
that this plugin will fail in a monorepo environment when dependnecies
get hoisted. This is because now there is no link to tailwind itself.
Marking it as a peerDependency should fix this, because now there is a
link. People that already have tailwind installed are good to go. People
that use monorepo's should benefit from this additional information.
Side note: NPM 7 starts installing peerDependencies for us https://github.com/npm/rfcs/blob/latest/implemented/0025-install-peer-deps.md
which is nice, because if we added an
explicit
dependency to Tailwind,then we would always reference our dependency and not the user's
dependency.
Closes: #31