MCPcopy Create free account
hub / github.com/TruthHun/BookStack / createWatcher

Function createWatcher

static/vuejs/vue.esm.js:2856–2866  ·  view source on GitHub ↗
(vm, key, handler)

Source from the content-addressed store, hash-verified

2854}
2855
2856function createWatcher (vm, key, handler) {
2857 var options;
2858 if (isPlainObject(handler)) {
2859 options = handler;
2860 handler = handler.handler;
2861 }
2862 if (typeof handler === 'string') {
2863 handler = vm[handler];
2864 }
2865 vm.$watch(key, handler, options);
2866}
2867
2868function stateMixin (Vue) {
2869 // flow somehow has problems with directly declared definition object

Callers 1

initWatchFunction · 0.70

Calls 1

isPlainObjectFunction · 0.70

Tested by

no test coverage detected