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

Function initMethods

static/vuejs/vue.runtime.esm.js:2817–2837  ·  view source on GitHub ↗
(vm, methods)

Source from the content-addressed store, hash-verified

2815}
2816
2817function initMethods (vm, methods) {
2818 var props = vm.$options.props;
2819 for (var key in methods) {
2820 vm[key] = methods[key] == null ? noop : bind(methods[key], vm);
2821 if (process.env.NODE_ENV !== 'production') {
2822 if (methods[key] == null) {
2823 warn(
2824 "method \"" + key + "\" has an undefined value in the component definition. " +
2825 "Did you reference the function correctly?",
2826 vm
2827 );
2828 }
2829 if (props && hasOwn(props, key)) {
2830 warn(
2831 ("method \"" + key + "\" has already been defined as a prop."),
2832 vm
2833 );
2834 }
2835 }
2836 }
2837}
2838
2839function initWatch (vm, watch) {
2840 for (var key in watch) {

Callers 1

initStateFunction · 0.70

Calls 3

bindFunction · 0.70
hasOwnFunction · 0.70
warnFunction · 0.50

Tested by

no test coverage detected