0.9.10 • Published 6 years ago

ng-input-currency v0.9.10

Weekly downloads
159
License
-
Repository
github
Last release
6 years ago

ng-input-currency

Build Status Coverage Status npm

Angular directive for formatting inputs as currency fields. This repo is inspired by format-as-currency.

Demo

http://jstroem.github.io/ng-input-currency/demo

Installation

Install via bower or NPM:

  • Bower: bower install --save ng-input-currency
  • NPM: npm install --save ng-input-currency

Usage

<div ng-controller="myController">
  <input ng-input-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', ['ngInputCurrency'])
  .controller('myController', function ($scope) {
    $scope.value = '' // currency input value
  });
</script>

With a module loader

Browserify

var formatAsCurrency = require('ng-input-currency')
angular.module('myModule', [ngInputCurrency])

Rollup

import * as ngInputCurrency from 'ng-input-currency'
angular.module('myModule', [ngInputCurrency])

Webpack

var ngInputCurrency = require('ng-input-currency')
angular.module('myModule', [ngInputCurrency])

Running the tests

npm test

Contributing

Contributions are welcome!

0.9.10

6 years ago

0.9.9

6 years ago

0.9.8

7 years ago

0.9.7

7 years ago

0.9.6

7 years ago

0.9.4

8 years ago

0.9.3

8 years ago

0.9.2

8 years ago

0.9.1

8 years ago

0.9.0

8 years ago