0
我在IIS 8上託管角色2+應用程序。所有路由都是客戶端路由,除了以/mutual-funds/*開頭的某些路由。對於那些路由,我想讓IIS獲得該文件夾並使用其索引頁。我已經寫了重寫規則,但它不能在重新加載。任何幫助,將不勝感激。Angular 2+應用程序IIS託管路線在重新加載時不起作用
的網絡配置文件是:
<rule name="AngularJS Routes" stopProcessing="false">
<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="/webapp/" />
</rule>
<rule name="Check1" stopProcessing="false">
<match url="/mutual-funds/"/>
<conditions logicalGrouping="MatchAll">
<add input="{ REQUEST_FILENAME}" matchType="IsFile" negate="true" />
<add input="{REQUEST_FILENAME}" matchType="IsDirectory" negate="true" />
</conditions>
<action type="Rewrite" url="/webapp/mutual-funds/" />
</rule>
我不想使用HashLocationStratgey。 –