Git Product home page Git Product logo

Comments (3)

otakustay avatar otakustay commented on August 25, 2024
  1. 说得没错,viewContext应该是一个初始化时设置后续不能更改的属性,不过既然现状已经是这样了,为了保持兼容性不可能修改
  2. 事实上initOptions没有处理viewContext,是在setProperties里处理的,而setProperties不仅仅初始化时,运行期也会不断被调用,所以这个问题和1是一样的
  3. 暂时没理解具体指的是什么

from esui.

hunter2009 avatar hunter2009 commented on August 25, 2024

对于1,2:能否把这个流程放入组件的构造函数中初始化,然后在dispose的时候进行销毁,这样修改的话对当前流程会有影响吗?兼容性呢?
对于3:对于ViewContext的操作,是不是写一个类似ViewContextGroup或者ViewContextManager的管理器来管理viewContext集合,比如说组件切换视图视图时,通过这个Manager来管理;这样也可以支持实例级别的复用?(虽然几乎不存在这样场景...但是对复用性有追求,用不到,但是我们可以有...)

from esui.

otakustay avatar otakustay commented on August 25, 2024

能否把这个流程放入组件的构造函数中初始化,然后在dispose的时候进行销毁,这样修改的话对当前流程会有影响吗?兼容性呢?

因为现在我们允许在组件初始化以后再改变viewContext(不可改变这个逻辑),所以肯定要在setProperties中支持修改,那么把这个流程放进初始化中去就是浪费

是不是写一个类似ViewContextGroup或者ViewContextManager的管理器来管理viewContext集合,比如说组件切换视图视图时,通过这个Manager来管理

现在的ViewContext本身就是这个Manager,提供了get等方法获取不同的ViewContext实例

from esui.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.