We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
Describe the bug When I use twin.macro with Styled Components in a React project, ESLint doesn't show errors.
To Reproduce Steps to reproduce the behavior:
Expected behavior It should show an error with the invalid Tailwind classes order.
Environment (please complete the following information):
Additional context Here's an example of the code that should show an error:
import tw from "twin.macro"; const AlertWrapper = tw.div`overflow-hidden relative rounded bg-slate p-7 py-5`; const AlertLine = tw.span`top-0 absolute left-0 w-2 h-full bg-primary`;
eslint config
module.exports = { root: true, env: { browser: true, es2020: true }, extends: [ "eslint:recommended", "plugin:@typescript-eslint/recommended", "plugin:react-hooks/recommended", "plugin:storybook/recommended", "plugin:tailwindcss/recommended", ], ignorePatterns: ["dist", ".eslintrc.cjs"], parser: "@typescript-eslint/parser", plugins: ["react-refresh"], rules: { "report-unused-disable-directives": 0, "react-refresh/only-export-components": [ "warn", { allowConstantExport: true }, ], }, overrides: [ { files: ["*.ts", "*.tsx", "*.js"], parser: "@typescript-eslint/parser", }, ], settings: { tailwindcss: { callees: ["classnames", "clsx", "ctl", "tw"], tags: ["tw"], classRegex: "^(class(Name)?)|(tw\\.\\w+)$", }, }, };
The text was updated successfully, but these errors were encountered:
Hi!👋 Do you find any solutions?
Sorry, something went wrong.
Released in v3.17.0Thank you @nihalgonsalves
v3.17.0
Successfully merging a pull request may close this issue.
Describe the bug
When I use twin.macro with Styled Components in a React project, ESLint doesn't show errors.
To Reproduce
Steps to reproduce the behavior:
Expected behavior
It should show an error with the invalid Tailwind classes order.
Environment (please complete the following information):
Additional context
Here's an example of the code that should show an error:
eslint config
The text was updated successfully, but these errors were encountered: