Replies: 1 comment
-
I have been frustrated by this problem for some time and this is what I do to work around it: @Component({
selector: 'app-title',
host: {
"[class]": "hostClasses()"
role: 'heading',
'aria-level': '1',
},
template: ` <ng-content></ng-content> `,
})
export class TitleComponent {
hostClasses = signal("block font-medium text-sm uppercase text-green-500 text-wrap font-bold");
} In {
"plugins": ["prettier-plugin-tailwindcss"],
"tailwindFunctions": ["signal"]
}
In { "tailwindCSS.classFunctions": ["signal"] } You can also add any other functions in the list that you might want to use like |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Hi,
in our team, we start using
host
-Atributes of a Component simplify style-overrides.Observation
Currently,
prettier-plugin-tailwindcss
seems not to recognizehost-class
.Question
How could we configure/enhance
prettier-plugin-tailwindcss
to sort tailwind-classes withinhost:class
?Pull-Request
I would like to help to create a PR for this.
I would need some guidance to start. :-)
Beta Was this translation helpful? Give feedback.
All reactions