Update element.js

Attr now doesn't serialize functions (second edition) #216