I was wondering how to automatically format a number in an input field using an angularjs directive? When I type in an input field say 6042919283 I want it to be shown as 6
I've used the ui-mask directive in AngularUI to mask fields in the past with great success. The documentation isn't very helpful, but here's a simple example of how to make it work.