Giter Site home page Giter Site logo

Comments (7)

Exodia avatar Exodia commented on May 27, 2024

对于这点,提供一个显示的通知方法如何。 vm.collection.xx = 1; vm.$notify();

from ub-ria.

Exodia avatar Exodia commented on May 27, 2024

或者用 Object.observe,应该有兼容库- -

from ub-ria.

otakustay avatar otakustay commented on May 27, 2024

有是有,我更关心这种方式是否合理,比如:

<esui-my-control data-ui-datasource="@foo"></esui-my-control>

其中foo是一个对象,那么当foo.bar变化时也同时通知到my-control是不是正确的……

from ub-ria.

Exodia avatar Exodia commented on May 27, 2024

angular的做法是有个 $watchCollection,使用者自己指定要检测某个集合的变化,默认只检测引用

from ub-ria.

otakustay avatar otakustay commented on May 27, 2024

就是说默认不提供这功能,开发者有需要的自己上?

对于$watchCollection,我们不需要专门这样的方法,emcColletion直接用就好,有要监听的就把数组转成Collection

from ub-ria.

Exodia avatar Exodia commented on May 27, 2024

是的,有需要自己上

from ub-ria.

otakustay avatar otakustay commented on May 27, 2024

嗯……我现在是拿列表作为一个典型场景在思考,筛选项如果在VM中体现为filters这样一个数组,其实就是要监听里面的每一项的value属性,相当于filters[i]['value'],确实挺深的

这种场景似乎还不少,唉……

from ub-ria.

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.