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

自定义节点成本高 #46

Closed
yhlchao opened this issue Mar 2, 2021 · 1 comment · Fixed by #51, #55 or #103
Closed

自定义节点成本高 #46

yhlchao opened this issue Mar 2, 2021 · 1 comment · Fixed by #51, #55 or #103
Labels
discussion help wanted Extra attention is needed

Comments

@yhlchao
Copy link
Collaborator

yhlchao commented Mar 2, 2021

version:0.2.*

目前自定义节点成本较高:

  1. 起步复杂,难上手
  2. 自定义步骤不明确
  3. 逻辑不便于理解
  4. 继承内部的简单节点后,效果却与简单节点不一致,失去继承的意义
  5. 坑较多,易受内部代码影响,不熟悉内部代码很难解决遇到的问题

期望:

  1. 上手快速,用最少的代码实现最简单的自定义元素
  2. 步骤明确,无论多复杂的自定义节点,只要跟着文档的步骤,都可以实现
  3. 用户代码清晰
  4. 继承内部节点的类后,不需要太多额外操作,就可以得到内部节点
  5. 消除内部代码对用户代码造成的未知影响
@yhlchao yhlchao added help wanted Extra attention is needed discussion labels Mar 2, 2021
@ggymm
Copy link

ggymm commented Mar 2, 2021

我就是有太多节点要添加,顺手写了个生成器。感兴趣可以试试
https://gitee.com/1967988842/flow_design/blob/master/scripts/node/run.js

读取iconfont.js里面的svg节点生成注册方法并且调用

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
discussion help wanted Extra attention is needed
Projects
None yet
2 participants