Check out example codes for "how to route back to url using Request.Headers["Referer"].ToString() in asp.net core". It will help you in understanding the concepts better.

Code Example 1

if(Request.Headers["Referer"] != null)
{
    ViewData["Reffer"] = Request.Headers["Referer"].ToString();
}

Code Example 2

@if(!string.IsNullOrWhiteSpace(ViewData["Reffer"]))
{
    <a href="@ViewData["Reffer"]">Return to client detail</a>
}

Learn ReactJs, React Native from akashmittal.com