I hosted my angular2 application in IIS and when I browse the application it is loading properly, when I refresh the page it is showing 404 error. To solve this I followed these links
2) http://jasonwatmore.com/post/2017/02/24/angular-2-refresh-without-404-in-node-iis
I created the following rule by referring the above two links
<?xml version="1.0" encoding="UTF-8"?>
<configuration>
<system.webServer>
<rewrite>
<rules>
<rule name="LogViwerRouting">
<match url=".*" />
<conditions logicalGrouping="MatchAll">
<add input="{REQUEST_FILENAME}" matchType="IsFile" negate="true" />
<add input="REQUEST_FILENAME}"matchType="IsDirectory"negate="true"/>
</conditions>
<action type="Rewrite" url="/" />
</rule>
</rules>
</rewrite>
</system.webServer>
If I refresh the page it should load the same page with all the changes being reverted, but it is not working as expected. Can anyone help me on this?