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

Function getTrustedContext

test/angular/1.4/angular.js:8921–8933  ·  view source on GitHub ↗
(node, attrNormalizedName)

Source from the content-addressed store, hash-verified

8919
8920
8921 function getTrustedContext(node, attrNormalizedName) {
8922 if (attrNormalizedName == "srcdoc") {
8923 return $sce.HTML;
8924 }
8925 var tag = nodeName_(node);
8926 // maction[xlink:href] can source SVG. It's not limited to <maction>.
8927 if (attrNormalizedName == "xlinkHref" ||
8928 (tag == "form" && attrNormalizedName == "action") ||
8929 (tag != "img" && (attrNormalizedName == "src" ||
8930 attrNormalizedName == "ngSrc"))) {
8931 return $sce.RESOURCE_URL;
8932 }
8933 }
8934
8935
8936 function addAttrInterpolateDirective(node, directives, value, name, allOrNothing) {

Callers 1

Calls 1

nodeName_Function · 0.70

Tested by

no test coverage detected