News for hackers. Stuff that matters.
Re:Parsley.js: never write a single JavaScript line to valid... by adamdicarlo on Sunday January 20, 2013 @02:24PM (#5087821)
Why use <input type="text" data-type="email"> rather than... <input type="email"> ? You're already using HTML5 data attributes, so why not use HTML5 input types? Added benefit is that the browser also has an idea of what kind of data goes there - this helps on mobile devices especially, where email fields won't auto-capitalize and might include extra buttons like the ".com" button and "@" right on the normal keyboard.
Re:Parsley.js: never write a single JavaScript line to valid... by guillaumepotier on Sunday January 20, 2013 @03:02PM (#5087972)
Right.

jQuery/Zepto $.data() was fast and easy to implement, rather than searching html5 attr.

I'll think about that ;)

Re:Parsley.js: never write a single JavaScript line to valid... by akoeberle on Monday January 21, 2013 @03:33AM (#5090548)
It shouldn't be that hard to use a attribute instead: var data = $( self ).attr(type);