MCPcopy Create free account
hub / github.com/angular-ui/ui-grid / jqLiteAddNodes

Function jqLiteAddNodes

lib/test/angular/1.6.7/angular.js:3401–3424  ·  view source on GitHub ↗
(root, elements)

Source from the content-addressed store, hash-verified

3399
3400
3401function jqLiteAddNodes(root, elements) {
3402 // THIS CODE IS VERY HOT. Don't make changes without benchmarking.
3403
3404 if (elements) {
3405
3406 // if a Node (the most common case)
3407 if (elements.nodeType) {
3408 root[root.length++] = elements;
3409 } else {
3410 var length = elements.length;
3411
3412 // if an Array or NodeList and not a Window
3413 if (typeof length === 'number' && elements.window !== elements) {
3414 if (length) {
3415 for (var i = 0; i < length; i++) {
3416 root[root.length++] = elements[i];
3417 }
3418 }
3419 } else {
3420 root[root.length++] = elements;
3421 }
3422 }
3423 }
3424}
3425
3426
3427function jqLiteController(element, name) {

Callers 2

JQLiteFunction · 0.70
angular.jsFile · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected