stencil-tailwind-plugin icon indicating copy to clipboard operation
stencil-tailwind-plugin copied to clipboard

No css files support

Open ohkimur opened this issue 2 years ago • 2 comments

It would be cool if by default the components without any reference to a CSS file guarantee the usage of the TW. At the moment it seems that if there aren't components with CSS files associated, the TW classes fail. I guess this happens because the TW utility classes are not included by default or something like that (more research might be necessary). However, when there is at least one component that has a reference to a CSS file, other components seem to not require the CSS file.

ohkimur avatar Sep 26 '22 08:09 ohkimur

Just so I can understand what you are asking ...

Normally you would have:

@Component({
    shadow: true,
    styleUrl: 'my-component.css',
    tag: 'my-component',
})

where my-component is the component and my-component.css is the associated stylings.

Is the idea to be able to support:

@Component({
    shadow: true,
    tag: 'my-component',
})

Then the TW styles would be injected into the my-component output from the compiler?

Poimen avatar Sep 30 '22 14:09 Poimen

@Poimen Yes. Exactly.

ohkimur avatar Oct 01 '22 18:10 ohkimur