如果是IIS上部署,添加一个web.config,内容:
<?xml version="1.0" encoding="UTF-8"?> <configuration> <system.webServer> <httpErrors> <remove statusCode="404" subStatusCode="-1" /> <error statusCode="404" prefixLanguageFilePath="" path="/index.html" responseMode="ExecuteURL" /> </httpErrors> </system.webServer> </configuration>