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

deep-mix方法跳过了undefined属性,使用的时候想将某些属性置空,但是不成功 #124

Open
QJerryxjh opened this issue Nov 29, 2024 · 1 comment

Comments

@QJerryxjh
Copy link

我使用了ant-design-charts的来源去向图,其中使用到了g6,g6依赖了咱们的util库。
组件渲染时为ant-design-charts组件重新传递edgeConfig的时候将一部分属性置空(ant-design-charts内部调用g6更新edge),g6通过deep-mix方法将原有属性config更新,cfg已经将某些属性置为undefined,但是没有成功。
image

undefined 在__deepMix中被忽略
上方已经判断了时候是hasOwn了,还要跳过undefined属性

@hustcc
Copy link
Member

hustcc commented Dec 4, 2024

设置为 null 呢?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants