角和IE8 - NG-视图中没有风格的HTML5元素 [英] Angular and IE8 -- HTML5 elements not styled inside ng-view

查看:183
本文介绍了角和IE8 - NG-视图中没有风格的HTML5元素的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

所以我试图让IE8角工作。我按照在 http://docs.angularjs.org/guide/ie 以及所有的步骤它似乎是工作 - 我看到的内容 NG-视图渲染IE8的时候我视图之间切换。

So I am trying to get angular working on IE8. I have followed all the steps on http://docs.angularjs.org/guide/ie and it seems to be working -- I see the content of ng-view rendered on IE8 when I switch between views.

问题是,我并没有真正看到在检查的内容:

The problem is that I don't actually see any content in the inspector:

..它只是一个空的NG-view标记。我的可以的看到所有页面上的内容,但无造型适用于任何在 NG-视图

.. it's just an empty ng-view tag. I can see all of the content on the page, but no styling is applied to anything inside ng-view.

我不知道这是否是一个角度或HTML5的问题。我已经添加了 html5shiv 以及HTML5元素纳克外-view 是很好的风格。

I am not sure whether this is an angular or HTML5 issue. I have added the html5shiv and HTML5 elements outside of ng-view are styled nicely.

修改

我已经确定,问题是HTML5元素。 <节> <物品> NG-视图中没有风格,虽然简单的div收到所有指定的样式。 NG-视图外<导航> <头> 的风格就好了。

I have determined that the problem is HTML5 elements. <section> and <article> are not styled inside ng-view, while simple divs receive all the specified styling. Outside of ng-view, <nav> and <header> are styled just fine.

推荐答案

我能够通过有条件包括jQuery的在IE8的基础上这里给出<一个答案来解决这个问题href=\"http://stackoverflow.com/a/18317832/2026098\">http://stackoverflow.com/a/18317832/2026098

I was able to fix this by conditionally including jQuery in IE8 based on answer given here http://stackoverflow.com/a/18317832/2026098

这篇关于角和IE8 - NG-视图中没有风格的HTML5元素的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆