laytan / tailwind-sorter.nvim

Easily sort Tailwind classes in Neovim.
MIT License
142 stars 12 forks source link

Not sorting in ruby erb for "class: 'hidden w-full'" #109

Open studious opened 1 week ago

studious commented 1 week ago

I have sorting work for most of my ruby eruby (.erb) files but the following class usage on the same page does not sort.

<%= link_to 'accounts', accounts_path, class: "pr-1 inline-block w-6 fill-indigo-600 hover:fill-indigo-900" %>

Should it sort and if I need to customise my nvim configs how do I go about doing this?

Thanks

studious commented 1 week ago

Ah, more digging and I think I see what's up. Embedded ruby in tree-sitter has no decent query mechanism. That's unfortunate. (output_directive (code) @cd)) is as close as I can get without more understanding.

Is that enough to potentially look for strings to sort?