Last active
August 9, 2020 05:00
-
-
Save vmilev/cf8ef05c2d77fc8aedd6c5831d724a77 to your computer and use it in GitHub Desktop.
Sample web.config for Angular 4 CLI app
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?xml version="1.0"?> | |
<configuration> | |
<system.webServer> | |
<staticContent> | |
<mimeMap fileExtension=".json" mimeType="application/json" /> | |
<mimeMap fileExtension=".woff" mimeType="application/x-font-woff" /> | |
<mimeMap fileExtension=".woff2" mimeType="font/woff2" /> | |
</staticContent> | |
</system.webServer> | |
<system.webServer> | |
<rewrite> | |
<rules> | |
<rule name="angular cli routes" stopProcessing="true"> | |
<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> | |
</configuration> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment