codenco-dev / nova-grid-system

Nova grid system for Laravel Nova
80 stars 33 forks source link

Is loading tailwind.css from an external source really necessary? #28

Closed pekka closed 1 year ago

pekka commented 1 year ago

New to Nova and Tailwind.

This package looks really nice, adding functionality that really should be in the core!

However, it seems to load tailwind.min.css from unpkg.com, while some version of Tailwind is also already loaded by Nova.

When I remove the new NovaGridSystem addition in NovaServiceProvider.php, which loads that external version of Tailwind, I see some change in the UI when using ->size() etc.... but not the desired changes.

Can anyone explain to me the difference between the on-board tailwind and the external one here? Is there a way to not use the external one? It does take a little to load, which shouldn't be a problem usually, but it also seems to subtly interfere with other aspects of the layout.

pekka commented 1 year ago

I've since found out that apparently, Nova only includes exactly the parts of tailwind that are needed to render Nova's interface for some reason. Presumably that is the rationale behind loading the entire thing yet again, and there's probably nothing that can be done about that without changing the way Nova works.