`RedirectToPage` should trim the trailing `/Index` from the URL given that it's default anyway. That is, doing this `return RedirectToPage("/Index");` should effectively be the same as `return Redirect("~/");`. Obviously needs to work for sub-folders and when route values are passed as well.
RedirectToPageshould trim the trailing/Indexfrom the URL given that it's default anyway.That is, doing this
return RedirectToPage("/Index");should effectively be the same asreturn Redirect("~/");.Obviously needs to work for sub-folders and when route values are passed as well.