Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

IE 9 下的 matchMediaPolyfill 没起作用,仍然报错 #936

Closed
someok opened this issue Jan 26, 2016 · 5 comments
Closed

IE 9 下的 matchMediaPolyfill 没起作用,仍然报错 #936

someok opened this issue Jan 26, 2016 · 5 comments

Comments

@someok
Copy link

someok commented Jan 26, 2016

Carousel 组件使用到 react-slick 中需要 matchMedia,Antd 中提供的 polyfill 在 ie9 下没起作用,仍然报错:

matchMedia not present, legacy browsers require a polyfill

环境说明:
采用 webpack + babel 编译

@afc163
Copy link
Member

afc163 commented Jan 26, 2016

polyfill 建议全局引用。

试试 http://ant.design/docs/react/getting-started#%E5%85%BC%E5%AE%B9%E6%80%A7 提供的这个 polyfill 。

media-match/2.0.2/media.match.min.js

@afc163
Copy link
Member

afc163 commented Feb 1, 2016

没有反馈了?

@someok
Copy link
Author

someok commented Feb 1, 2016

目前我没有用到这个组件,而且打包使用了Babel-antd插件,所以没再遇到这个问题,晚上我再试试
偏右 notifications@github.com于2016年2月1日 周一11:54写道:

没有反馈了?


Reply to this email directly or view it on GitHub
#936 (comment)
.

@someok
Copy link
Author

someok commented Feb 4, 2016

采用上面那个 polyfill 之后,ie9 下正常了

@lock
Copy link

lock bot commented May 6, 2018

This thread has been automatically locked because it has not had recent activity. Please open a new issue for related bugs and link to relevant comments in this thread.

@lock lock bot locked as resolved and limited conversation to collaborators May 6, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants