format-as-currency

Angular directive to format an input as a currency as the user types

Homepage

Angular Core Dependency: ~1.3.14

Module License: CC0

Added by: Sam Deering

GitHub

Repository

bcherny/format-as-currency

Stats

Stars: 2

Watchers: 2

Forks: 0

Module Description

format-as-currency

Build Status Coverage Status npm cc0

Angular directive to format an input as a currency as the user types. Like autoNumeric for Angular.

Demo

http://bcherny.github.io/format-as-currency/demo

Installation

Install via bower or NPM:

  • Bower: bower install --save format-as-currency
  • NPM: npm install --save format-as-currency

Usage

<div ng-controller="myController">
  <input
    format-as-currency
    ng-model="value"
    type="text"
  >
</div>

<script src="bower_components/angular/angular.js"></script>
<script src="bower_components/format-as-currency/format-as-currency.js"></script>
<script>
  angular
  .module('myModule', [
    'bcherny/formatAsCurrency'
  ])
  .controller('myController', function ($scope) {
    $scope.value = '' // currency input value
  })
</script>

Running the tests

npm test

Module stats last updated: 2015-06-08 00:24:37

Disclaimer: Some data on this page may have been gathered from the authors GitHub respository. If you see any mistakes or outdated information please let us know. Thanks!