MCPcopy Index your code
hub / github.com/keepfool/vue-tutorials / linkAndCapture

Function linkAndCapture

01.GettingStarted/js/vue.js:6917–6928  ·  view source on GitHub ↗

* Apply a linker to a vm/element pair and capture the * directives created during the process. * * @param {Function} linker * @param {Vue} vm

(linker, vm)

Source from the content-addressed store, hash-verified

6915 */
6916
6917 function linkAndCapture(linker, vm) {
6918 /* istanbul ignore if */
6919 if ('development' === 'production') {}
6920 var originalDirCount = vm._directives.length;
6921 linker();
6922 var dirs = vm._directives.slice(originalDirCount);
6923 dirs.sort(directiveComparator);
6924 for (var i = 0, l = dirs.length; i < l; i++) {
6925 dirs[i]._bind();
6926 }
6927 return dirs;
6928 }
6929
6930 /**
6931 * Directive priority sort comparator

Callers 3

compileFunction · 0.70
compileAndLinkPropsFunction · 0.70
compileRootFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected