tailwindlabs / tailwindcss-custom-forms

A better base for styling form elements with Tailwind CSS.
https://tailwindcss-custom-forms.netlify.app/
MIT License
1.55k stars 72 forks source link

Issue when upgrading to TW v2 #88

Open usernotnull opened 4 years ago

usernotnull commented 4 years ago

After upgrading to Tailwind v2 (with postcss7 compat), requiring this plugin in my tailwind.config.js throws the following error on npm run:

Module build failed (from ./node_modules/css-loader/index.js):
ModuleBuildError: Module build failed (from ./node_modules/postcss-loader/src/index.js):
TypeError: value.charCodeAt is not a function at

At this line in my scss: @tailwind components;

Is this plugin ready for the tailwind upgrade yet or might it be another issue from my side?

ghost commented 4 years ago

I think they recommend https://github.com/tailwindlabs/tailwindcss-forms for v2

usernotnull commented 4 years ago

Probably time to mark this project as abandoned with a link in the description to the new tailwind forms

deantheiceman commented 4 years ago

How do we use the new one while keeping the same styles

wobsoriano commented 4 years ago

I think they recommend https://github.com/tailwindlabs/tailwindcss-forms for v2

Looking at the commits, I think they're preparing for Tailwind 2 compatibility https://github.com/tailwindlabs/tailwindcss-custom-forms/pull/79

rhukster commented 4 years ago

I switched from custom to tailwindcss-forms + some custom CSS to apply my form styling (which I previously had set in tailwind.config.js) based on class names as I can't easily modify every field individually.

wobsoriano commented 4 years ago

Yep, looks like they're not planning on supporting Tailwind CSS 2

https://twitter.com/adamwathan/status/1330846547039367169

ghost commented 3 years ago

It's all in docs https://tailwindcss.com/docs/upgrading-to-v2#update-typography-and-forms-plugins

If you are using @tailwindcss/custom-forms, you will want to migrate to @tailwindcss/forms which replaces it. Learn more about the new forms plugin in the release notes.

The @tailwindcss/custom-forms plugin is not compatible with Tailwind CSS v2.0.