joestelmach/laconic — pull request #6 by enaeseth (2012-10-24 00:39:39+00:00)
Title: Fix creating a button with a type under IE7

A ``'s type cannot be changed with `setAttribute` under IE7:

```javascript
var button = document.createElement("button");
button.setAttribute("type", "submit");

console.log(button.getAttribute("type")); // "submit" (even in IE7)
console.log(button.type); // "button" in IE7
```

The button continues to act like ``, and it cannot be used to submit a form in IE7 without adding a click event handler.

The only workaround I know of is IE's proprietary `createElement` syntax where you can specify attributes inline, and this pull request implements that workaround.