In my ASP.NET SPA application I am using web.config to set Rewrite Rules, so I can refresh pages without error (while using Angularjs), but I also would like to redirect to application's homepage, when non-existing page manually entered into url, please advise how should I modify code below to accommodate this:
<rewrite>
<rules>
<rule name="Products" stopProcessing="true">
<match url="^products" />
<action type="Rewrite" url="/" />
</rule>
<rule name="Orders" stopProcessing="true">
<match url="^orders" />
<action type="Rewrite" url="/" />
</rule>
<rule name="Home" stopProcessing="true">
<match url="^home" />
<action type="Rewrite" url="/" />
</rule>
<rule name="List" stopProcessing="true">
<match url="^list" />
<action type="Rewrite" url="/" />
</rule>
</rules>
</rewrite>