MCPcopy Index your code
hub / github.com/TruthHun/BookStack / observe

Function observe

static/vuejs/vue.runtime.esm.js:787–807  ·  view source on GitHub ↗

* Attempt to create an observer instance for a value, * returns the new observer if successfully observed, * or the existing observer if the value already has one.

(value, asRootData)

Source from the content-addressed store, hash-verified

785 * or the existing observer if the value already has one.
786 */
787function observe (value, asRootData) {
788 if (!isObject(value)) {
789 return
790 }
791 var ob;
792 if (hasOwn(value, '__ob__') && value.__ob__ instanceof Observer) {
793 ob = value.__ob__;
794 } else if (
795 observerState.shouldConvert &&
796 !isServerRendering() &&
797 (Array.isArray(value) || isPlainObject(value)) &&
798 Object.isExtensible(value) &&
799 !value._isVue
800 ) {
801 ob = new Observer(value);
802 }
803 if (asRootData && ob) {
804 ob.vmCount++;
805 }
806 return ob
807}
808
809/**
810 * Define a reactive property on an Object.

Callers 5

vue.runtime.esm.jsFile · 0.70
defineReactive$$1Function · 0.70
validatePropFunction · 0.70
initStateFunction · 0.70
initDataFunction · 0.70

Calls 4

isObjectFunction · 0.70
hasOwnFunction · 0.70
isServerRenderingFunction · 0.70
isPlainObjectFunction · 0.70

Tested by

no test coverage detected