Here is my rule to set up rewrite rules to serve a React app’s index.html file and it is not working for me, here is the url input http://mypage.com/Error/NotFound?aspxerrorpath=xxxxxxx, I am not sure what I am missing here and I put index.html at the root level. Thanks for the help.
<rewrite>
<rules>
<rule name="Redirect to React pages" stopProcessing="true">
<match url="(.*)" ignoreCase="false" />
<condition>
<add input="{URL}" pattern="^/Error/NotFound" ignoreCase="false" negate="true" />
</condition>
<action type="Redirect" url="/index.html" redirectType="Permanent" />
</rule>
</rules>
</rewrite>
New contributor
user25088797 is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.