Closed adamkiss closed 2 years ago
Good point for plugin devs. Looks like a nice addition to the README of the Tailwind example. Will add that.
Much appreciated you took a look into this and wrote this issue, @adamkiss!
Added a note based on your words in https://github.com/johannschopplich/kirbyup/commit/6229e5baf1d9457f8e1256e4d4f85f31b32b4d80.
I'm not sure this necessarily belongs here, but I've just spent an hour debugging it, and I thought it should be noted somewhere, and since
kirbyup + tailwind
is one of the official examples, I thought you might want to include a warning or a note:If you're using kirbyup with tailwind in two separate plugins, and the latter uses the same class as the one loaded earlier, it might happen that your responsive tailwind classes will stop working, since kirby just smushes the generated CSS together into one CSS file.
Example:
Now the element with
p-2 lg:p4
from first plugin will stay atp-2
, since the second plugin redefines thep-2
class much later in the resultingindex.css
file.Solutions: