import attributeLookup from './lookup.js'; import createBinding from './binding/index.js'; import deindent from '../../utils/deindent.js'; export default function addElementAttributes ( generator, node, local ) { node.attributes.forEach( attribute => { if ( attribute.type === 'Attribute' ) { let metadata = attributeLookup[ attribute.name ]; if ( metadata && metadata.appliesTo && !~metadata.appliesTo.indexOf( node.name ) ) metadata = null; if ( attribute.value === true ) { // attributes without values, e.g.