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

Function wrapTemplate

test/angular/1.4/angular.js:8907–8918  ·  view source on GitHub ↗
(type, template)

Source from the content-addressed store, hash-verified

8905
8906
8907 function wrapTemplate(type, template) {
8908 type = lowercase(type || 'html');
8909 switch (type) {
8910 case 'svg':
8911 case 'math':
8912 var wrapper = document.createElement('div');
8913 wrapper.innerHTML = '<' + type + '>' + template + '</' + type + '>';
8914 return wrapper.childNodes[0].childNodes;
8915 default:
8916 return template;
8917 }
8918 }
8919
8920
8921 function getTrustedContext(node, attrNormalizedName) {

Callers 3

compileFunction · 0.70
applyDirectivesToNodeFunction · 0.70
compileTemplateUrlFunction · 0.70

Calls 1

lowercaseFunction · 0.70

Tested by

no test coverage detected