With the concept of web app routing, we deal with each page context in a period of its lifecycle, which starts from pre-invoking the request to un-mounting its content. And we provide serveral callbacks in certain points of each lifecycle to let you control the whole page context flow.
This function is invoked only once, which is after the component instance has been initialized.
This function is invoked only once, which is before the page is going to redirect to another page. The redirect-to page's URL is passed as the argument.
false
in the function, it will not redirect.This function is invoked before the AJAX request is made.
If you return false
in the function, no AJAX request will be made, and this routing flow for current URL will end.
This function is invoked when the AJAX request failed.
This function is invoked before updating the host page content with the AJAX returned html string
If you return false
in the function, no update will be made, and this lifecycle will end.
This function is invoked after the host page content has been updated to the returned AJAX request.
This function is invoked when host page content has failed updating its content. Mostly it is because there is some JavaScript errors thrown out in the inline script of the embeded page.
This function is invoked when a link is clicked in the embeded page.
This function is invoked when a form is about to be sumbitted in the embeded page.