Yes,
a PR would be nice. However, please don't leave it in the directive.


On Fri, Feb 7, 2014 at 8:56 AM, Ben Lesh <notifications@github.com> wrote:

> In src/ng/directive/input.js:
>
> > @@ -89,7 +94,345 @@ var inputType = {
> >     */
> >    'text': textInputType,
> >
> > +    /**
> > +     * @ngdoc inputType
> > +     * @name ng.directive:input.date
> > +     *
> > +     * @description
> > +     * HTML5 or text input with date validation and transformation. In browsers that do not yet support
> > +     * the HTML5 date input, a text element will be used. The text must be entered in a valid ISO-8601
> > +     * date format (yyyy-MM-dd), for example: `2009-01-06`. Will also accept a valid ISO date or Date object
>
> I considered the same thing. However, this seems like the *easiest* place
> to do it though, because this is a point, where you have a string that was
> just identified, for the first time, as being a Date. At any point prior to
> this in it's life cycle, there just really isn't an efficient way of
> identifying it, without explicitly mapping conversions, or inefficiently
> traversing the object looking for dates to convert.
>
> In order for Angular to be buttery-smooth with Dates and these HTML5
> controls, some sort of seamless conversion is nearly a must. Would you like
> me to put in a PR or two for some options regarding converting strings to
> dates?
>
> I actually have a service I made to convert a string to a date, taking
> into account $locale.
>
> —
> Reply to this email directly or view it on GitHub<https://github.com/angular/angular.js/pull/5864/files#r9546086>
> .
>