A template is a relative URL, so it mustn't start with a slash (/). In it, you define the structure of your site, or, more accurately, the structure that you intend to make available. As ASP.NET Core is an MVC framework, the template should describe how to map the request to an action method in a controller. The following is the template:
{controller=Home}/{action=Index}/{id?}
It consists of sections separated by slashes, where each section has some tokens (inside curly braces).
Another example would be this:
sample/page
Here it is not clear what we want, as there are no mentions of controller or action. However, this is a perfectly valid template, and the required information needs to come from elsewhere.
A template can have the following elements:
- Alphanumeric literals
- String fragments inside curly braces ({}), which are named tokens and can be mapped to action method parameters...