Socket
Book a DemoInstallSign in
Socket

mat-currency-format

Package Overview
Dependencies
Maintainers
1
Versions
7
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

mat-currency-format

This repos is creating a library for angular currency input and also it is showing how to use the library

0.0.7
latest
npmnpm
Version published
Weekly downloads
412
-15.05%
Maintainers
1
Weekly downloads
 
Created
Source

MatCurrencyFormat

This repos is creating a library for angular currency input and also it is showing how to use the library

This library was generated with Angular CLI version 8.1.3.

Installation - mat currency-format

$ npm i mat-currency-format

Description

The directive can be used in html input to automatically change the input to locale currency.

  • Input in any locale currency convert to number inside the component. On focus the user will see to type in number and on focus out the user will see the number in currency format with the support of internalization format and currency symbol

  • The selector name of the directive is localeCurrencyInput

  • The directive consists of two inputs:

    • currencyCode (default value = 'USD')
    • allowNegative (default value = false)

Demo

     import  {MatCurrencyFormatModule} from 'mat-currency-format';

Inside the view you need to call mvndrMatCurrencyFormat and add input. Below is one of the example

<input type="text"
      mvndrMatCurrencyFormat
      [allowNegative]="false"
      [currencyCode]="'USD'"
      [value]="usAmount"
      (blur)="updateUSAmount($event)" />
  • Inside the component you can get the value by using event like blur or click or any other event. Below is one of the example updateUSAmount(event) { this.usAmount = event.target.value; }

Keywords

currency

FAQs

Package last updated on 21 Dec 2019

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

About

Packages

Stay in touch

Get open source security insights delivered straight into your inbox.

  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc

U.S. Patent No. 12,346,443 & 12,314,394. Other pending.