Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unable to use with Rails helpers #212

Open
codepilotsf opened this issue Oct 24, 2024 · 0 comments
Open

Unable to use with Rails helpers #212

codepilotsf opened this issue Oct 24, 2024 · 0 comments

Comments

@codepilotsf
Copy link

I'm trying to get Headwind working with Rails helpers which look like this:
<%= some_helper, class: "text-blue-500 font-bold" %>

I've read the docs and tried adding this to my settings.json:

"headwind.classRegex": {
    "erb": "\\bclass\\s*:\\s*[\\\"\\']([\\._a-zA-Z0-9\\s\\-\\:\\/]+)[\\\"\\']",
    "html": "\\bclass\\s*:\\s*[\\\"\\']([\\._a-zA-Z0-9\\s\\-\\:\\/]+)[\\\"\\']",
  },

...but nothing seems to work. Not entirely sure this is a bug but perhaps it reveals a documentation shortcoming? Any tips would be greatly appreciated. Note that Headwind works great with regular HTML tags <p class="...">.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant