commands.reduce is not a function code example
Example: commands.reduce is not a function angular router
//The destination route should be wrapped in brackets.
function_to_call_navigation(destination_route) {
this.router.navigate([destination_route]);
}