Search code examples
javascriptdesign-patternsvue.jsobserver-pattern

Vue.js and Observer Pattern


Is data binding or event handling of Vue.js associated with Observer pattern of Design Pattern?

I listened from my co-worker. He said Frontend-framework's data binding or event handling is associated with Observer Pattern. He also said 'If you wanna know about two-ways-binding, I think you should research observer-pattern'


Solution

  • Vue's Reactivity system is definitely an example of the Observer Pattern:

    https://v2.vuejs.org/v2/guide/reactivity.html