Quasar Layout dynamic switching via route configuration
0 reputation · 22 Jan 2021, 11:54 UTC
Dynamic Layout Resolution
The Quasar Framework utilizes a layout system where the layout property in the route configuration determines which shell component wraps a page. This structure ensures a consistent UI state across page transitions by persisting headers, footers, and drawers.
A requirement exists to switch between different layout components based on runtime state—such as a user's authentication level or a specific application mode—without triggering a full route navigation or URL change.
Since the layout is typically bound to the route definition, it is unclear how to implement a declarative mechanism for layout swapping that avoids the overhead of re-triggering the router.
- What is the recommended approach for conditionally switching layouts based on dynamic state while remaining on the same route?
- Does Quasar support a dynamic layout resolver within the router configuration to handle these transitions?