lapis icon indicating copy to clipboard operation
lapis copied to clipboard

[Bug] Sub-application layouts do not work?

Open TangentFoxy opened this issue 9 years ago • 3 comments

I assumed I would be able to have a views/layout.moon for example, and then within a sub-application, declare that as the layout with layout: require "views.layout", but that doesn't work.

What other kinds of things don't work with sub-applications the way they do with a master application? Or did I mess something up?

TangentFoxy avatar Aug 22 '16 21:08 TangentFoxy

sub applications work by copying everything into the parent application, but optionally scoping each action's name/path with the parameters provided in the layout. Before filters are applied before copying as well, so they should work as expected

leafo avatar Aug 22 '16 22:08 leafo

So, name/path and before filters are the only features that work with sub-applications?

TangentFoxy avatar Aug 23 '16 00:08 TangentFoxy

yup https://github.com/leafo/lapis/blob/master/lapis/application.moon#L208

leafo avatar Aug 23 '16 00:08 leafo