-
In my last question I was confused about the flash messages not rendering... the reason turns out to be that my custom layout isn't working. I feel like I already did this before, but I can't figure out how if I did. My rodauth-rails views are being rendered in my Rails' default "applciation" layout, which is highly unsuitable for my rodauth-rails use-case. I see that the render plugin is configured within Rodauth-rails, but I'm not sure how to override that config. I have a "parent" controller for my rodauth-rails authenticated routes on the Rails side, and I've set I'll try directly overriding the |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments 2 replies
-
Can't get it to work. I see:
I tried:
And:
And a copy of the rodauth-rails internal line, swapping in the name of the alternate layout:
My layout designations appear to have no effect at all. No errors, and no indication that I've changed anything at all. The layout is simply ignored. |
Beta Was this translation helpful? Give feedback.
-
rodauth-rails loads the You change the layout in |
Beta Was this translation helpful? Give feedback.
rodauth-rails loads the
render
Roda plugin only to be able to render Rodauth's built-in views, which are in Tilt and within a Roda instance. It only gets the page HTML, and forwards it to a Rails controller, which renders the layout, because that's a Rails view template rendered in Rails view context.You change the layout in
RodauthController
, just like you do for normal Rails views, see https://github.com/janko/rodauth-rails/wiki/Different-layout.