abortNavigation(err?: Error | string): false
abortNavigation()
Inside a route middleware handler, abortNavigation() will abort navigation, and throw an error if one is set as a parameter.