Skip to main content

End Page

Call FSPage#end to mark the end of the view of the page. This will make the current page not defined, if the page is the current page. If the page is not the current page, this will have no effect.

Calling this method is only needed if you intend to leave portions of your app without defined pages. Otherwise, it is recommended to not call this method. For example, you may only wish to define pages for a checkout flow within your app. You would want to call end so when the user leaves the flow other portions of the app without defined pages won't be treated as part of the checkout page.

FSPage#end is analogous to dispose in a StatefulWidget's lifecycle and should typically be called there, if at all.

Note: ending a page is reversible, disposing one is not. Call page.start() to resume a page that was previously ended, but not disposed.

Additional Information

end()

Example Invocation

late FSPage page; // Initialized in initState

@override
void dispose() {
_page.end();
_page.dispose();
super.dispose();
}