- html - 出于某种原因,IE8 对我的 Sass 文件中继承的 html5 CSS 不友好?
- JMeter 在响应断言中使用 span 标签的问题
- html - 在 :hover and :active? 上具有不同效果的 CSS 动画
- html - 相对于居中的 html 内容固定的 CSS 重复背景?
这是存储库:
https://github.com/vipul-verma/naysa
如果您下载并在本地运行它,它就可以工作。
这是预览页面:
https://rawgit.com/vipul-verma/naysa/master/index.html
问题:Rawgit.com 仅显示菜单,它不加载 slider 和关于页面的 View 。
任何解决方案!!
最佳答案
你的 templateUrls 是绝对的,所以当 url 不是 root 时它会加载失败(在 rawgit 上也是如此)。它尝试加载 https://rawgit.com/partials/slider.html
而不是 https://rawgit.com/vipul-verma/naysa/master/partials/slider.html
.
尝试改变
views: {
'viewSlider' : {
templateUrl: "/partials/slider.html"
},
'viewAbout' : {
templateUrl: "/partials/about.html"
}
}
到
views: {
'viewSlider' : {
templateUrl: "partials/slider.html" // <- remove slash on start
},
'viewAbout' : {
templateUrl: "partials/about.html" // <- remove slash on start
}
}
关于javascript - ui 路由器未加载 rawgit 中的 View ,但在本地工作,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/35575147/
这段代码我做错了什么?当我使用本地源作为主题时,它可以正常工作,但不能来自 github。我浏览了很多帖子,但似乎找不到为什么这不起作用,它也是如此简单的代码。问题出在第二个带有主题的脚本中,但我不知
我正在使用 cdn.rawgit.com 来托管我的一些脚本和项目的 css,但我无法刷新它。根据常见问题解答: Requests to cdn.rawgit.com are routed throu
我正在尝试通过 Ajax 在我的网站中包含一个 JS 文件,方法是使用 Rawgit 从我的 GitHub 存储库之一获取它。出于某种原因,当我使用开发或生产 URL 时它不起作用,但是当我直接从 G
我想通过 RawGit 使用 wget 检索文件。我正在使用的命令: wget raw.githubusercontent.com/DevBonBon/The_Thing/Finish-Tim-The
所以我是 javascript 的新手,我正在努力从这里稍微修改代码 https://github.com/virajsanghvi/d3.basketball-shot-chart 几周前它还在工作
这是存储库: https://github.com/vipul-verma/naysa 如果您下载并在本地运行它,它就可以工作。 这是预览页面: https://rawgit.com/vipul-ve
我是一名优秀的程序员,十分优秀!