结合AngularJS,HTML5位置和超迷
发布时间:2020-12-17 17:20:48 所属栏目:安全 来源:网络整理
导读:我一直在使用nodejs http-server来提供我的Angular应用程序,但它不适用于 HTML5位置,因为使用它们需要服务器重定向,而http-server不会这样做.所以我看到了推荐尝试 superstatic并安装它.然后我设置以下superstatic.json文件: { "routes": { "Admin/**":"/in
我一直在使用nodejs http-server来提供我的Angular应用程序,但它不适用于
HTML5位置,因为使用它们需要服务器重定向,而http-server不会这样做.所以我看到了推荐尝试
superstatic并安装它.然后我设置以下superstatic.json文件:
{ "routes": { "Admin/**":"/index.html","Give/**":"/index.html","Pending/**":"/index.html","Store/**":"/index.html" } } 我推出了它 superstatic --config superstatic.json 虽然如果我以“/”开头它正确地提供了我的应用程序,重新加载index.html文件,但不要对文件进行任何角度处理. 有没有人成功地使用带角度的迷信? 解决方法
通过设置我的superstatic.json,我得到了完美的工作:
{ "rewrites": [ {"source":"/**","destination":"/index.html"} ] } 然后运行它 superstatic --config superstatic.json (编辑:李大同) 【声明】本站内容均来自网络,其相关言论仅代表作者个人观点,不代表本站立场。若无意侵犯到您的权利,请及时与联系站长删除相关内容! |