dart-lang/dart-web-components — pull request #87 by sqs (2012-10-15 09:50:06+00:00)
Title: Handle HTML element attributes with hyphens (e.g., <div data-abc="{{xyz}}">)

This patch lets DataBindingEmitter handle bindings in attributes with hyphens, such as `data-` attributes. Previously, attempting to use `

` would cause an error like:

````CONSOLE MESSAGE: Internal error: '_bind_hyphenated_attribute_test.html.dart': Error: line 35 pos 16: identifier 'abc' is not declared in this scope
___e0.data-abc = e.newValue;
````

Now, `data-` attributes are special cased. This is not a robust fix, but it fixes this immediate issue. Another possible fix is to use `$elemField.attributes["$name"] = e.newValue;` for all non-class bindings, but this is the more minimal fix.