\u0000Could someone point me to an example of VerticalLayout that includes a footer…?\n\nThe footer needs to stay in position at the bottom of the page, even if the main content changes.\n\n\uD83D\uDE4F\uD83C\uDFFB
Something like this will work, assuming a simple scenario and that there is not too much content that the footer won’t fit.
verticalLayout.setSizeFull();
// Wrapper to use up extra space
FlexLayout footerWrapper = new FlexLayout();
// Actual footer content
Div footer = new Div();
footer.setText("Footer");
// Align the footer to the end of the wrapper
footerWrapper.setAlignItems(Alignment.END);
// Make the footer always last in the parent using FlexBox order
footerWrapper.getElement().getStyle().set("order", "999");
footerWrapper.add(footer);
verticalLayout.add(footerWrapper);
// expand the wrapper to take all remaining unused space
verticalLayout.expand(footerWrapper);
\u0000Much appreciated Olli. \uD83D\uDC4D\uD83C\uDFFB