Pages, layouts and parts with same name in libs vs apps

Enonic version: 6.7.1
OS: Mac and Linux

So a typical name for a layout could be “grid”.

Now both a library and the app comes with it’s own version of grid, which are not compatible.

Currently it seems to me only the app version becomes available in content studio.

It could be even a bit more complex.

We have library L build into library M which is build into App A.
What if all of them had components with the same names…

Basing component “id’s” strictly on “app.name:component.name” is not exact.

Thoughts?

When a library is included in an app compile time it “disappears” and becomes part of the app - so runtime there is no way of accessing the library directly. XP is using a classloading principle, so the highest priority layout will be the only one left visible in the end. If you want both layouts, give the layout in the app a different name - if you want to override the library layout, place a layout with the same name in the app.

If multiple libraries ship with the same layout, class loading order will apply