Skip to content

Vuedraggable、Carousel组件打包后不兼容 ie浏览器 #2518

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

Closed
1 task
wxwebfeng opened this issue Jul 3, 2020 · 3 comments
Closed
1 task

Vuedraggable、Carousel组件打包后不兼容 ie浏览器 #2518

wxwebfeng opened this issue Jul 3, 2020 · 3 comments
Labels

Comments

@wxwebfeng
Copy link

  • I have searched the issues of this repository and believe that this is not a duplicate.

Version

1.5.1

Environment

window 10 / IE11 / Vue ^2.6.11

Reproduction link

https://www.antdv.com/components/layout-cn/

Steps to reproduce

1.在本地运行是能展示;
2.打包后发布到服务器;
3.轮播组件 slot 未加载数据(轮播内容)

What is expected?

1.期待能兼容ie

What is actually happening?

没有加载slot(轮播内容)

@sendya
Copy link
Member

sendya commented Jul 4, 2020

能提供复现吗?

@wxwebfeng wxwebfeng changed the title Carousel 组件 打包后 不兼容 ie浏览器 Vuedraggable、Carousel组件打包后不兼容 ie浏览器 Jul 6, 2020
@wxwebfeng
Copy link
Author

@sendya 不好意思,是我们这边的问题,组件引用顺序问题!感觉很奇怪,Number 会被修改掉(只有在ie浏览器,而且是打包后),
Number.toString(): function(t){var e=arguments.length<1?0:t,n=this;return n instanceof O&&(x?h((function(){b.valueOf.call(n)})):c(n)!=m)?u(new y(w(e)),n,O):w(e)}; // 该函数 prototype —> Number;

Carousel props 初始参数 那里Number类型数据就会为undefined;

ant-design-vue —> lib —> _util —> utils.js 中 var getType = exports.getType = function getType(fn) { var type = fn !== null && fn !== undefined ? fn.type ? fn.type : fn : null; var match = type && type.toString().match(FN_MATCH_REGEXP); return match && match[1]; }; // 造成 match[1] 为undefined 所以赋值default: undefined, 走马灯出错

如果 Carousel 组件 先于 Vuedraggable 引入 就不会 造成 Number 修改问题;

@wxwebfeng wxwebfeng reopened this Jul 6, 2020
@github-actions
Copy link

This issue has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Aug 30, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

No branches or pull requests

2 participants