MCPcopy
hub / github.com/angular-ui/ui-router / JQLite

Function JQLite

test/angular/1.3/angular.js:2518–2541  ·  view source on GitHub ↗
(element)

Source from the content-addressed store, hash-verified

2516
2517/////////////////////////////////////////////
2518function JQLite(element) {
2519 if (element instanceof JQLite) {
2520 return element;
2521 }
2522
2523 var argIsString;
2524
2525 if (isString(element)) {
2526 element = trim(element);
2527 argIsString = true;
2528 }
2529 if (!(this instanceof JQLite)) {
2530 if (argIsString && element.charAt(0) != '<') {
2531 throw jqLiteMinErr('nosel', 'Looking up elements via selectors is not supported by jqLite! See: http://docs.angularjs.org/api/angular.element');
2532 }
2533 return new JQLite(element);
2534 }
2535
2536 if (argIsString) {
2537 jqLiteAddNodes(this, jqLiteParseHTML(element));
2538 } else {
2539 jqLiteAddNodes(this, element);
2540 }
2541}
2542
2543function jqLiteClone(element) {
2544 return element.cloneNode(true);

Callers 1

angular.jsFile · 0.70

Calls 4

isStringFunction · 0.70
trimFunction · 0.70
jqLiteAddNodesFunction · 0.70
jqLiteParseHTMLFunction · 0.70

Tested by

no test coverage detected