Closed azal-io closed 3 years ago
I tried a different approach on this one. Added a before action to set the layout for Engine's template.
I guess if we do with initializer then let's say that we have another engine with inertia and the app will get confuse about which 2 initializers to choose from. I guess by having it under Engine's App Ctrl we make sure that each engine selects its own template. On concern though, applying the same layout config over and over again. I guess caching won't work as well since we need to change the layout for the other Engine. Does anyone has any suggestion on this?
Thanks
Hey @azal-io I'm not really sure of what you're trying to do here. You're trying to write a rails engine based around inertia and its not working as expected?
This isn't something we've tried internally, so I'm not sure where to start. Do you have an example we could look at?
Inertia doesn't work in Rails Engine. It selects Main App's Application layout. Added initializer to engine but it is not getting picked up, and Inertia selects App's layout.
Could you please confirm whether this works in a Rails engine?
Thanks