MCPcopy Create free account
hub / github.com/ampproject/amphtml / boundPropertiesInElement_

Method boundPropertiesInElement_

extensions/amp-bind/0.1/bind-impl.js:966–977  ·  view source on GitHub ↗

* Returns bound properties for an element. * @param {!Element} element * @return {!Array<{property: string, expressionString: string}>} * @private

(element)

Source from the content-addressed store, hash-verified

964 * @private
965 */
966 boundPropertiesInElement_(element) {
967 const boundProperties = [];
968 const attrs = element.attributes;
969 for (let i = 0, numberOfAttrs = attrs.length; i < numberOfAttrs; i++) {
970 const attr = attrs[i];
971 const boundProperty = this.boundPropertyInAttribute_(attr, element);
972 if (boundProperty) {
973 boundProperties.push(boundProperty);
974 }
975 }
976 return boundProperties;
977 }
978
979 /**
980 * Returns the bound property and expression string within a given attribute,

Callers 1

scanElement_Method · 0.95

Calls 2

pushMethod · 0.45

Tested by

no test coverage detected