Skip to content

AngularJS directive that converts to/from metric units using $parser and $formatters

License

Notifications You must be signed in to change notification settings

bekopharm/angular-unit-converter

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

17 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

AngularJS Unit Converter Build Status

AngularJS directive that converts to/from metric units using $parser and $formatters

How does it works

The idea behind this directive is to take a model's value and convert it from one unit to another, say from cm to mm, without changing the value itself, only the view value. Of course, the reverse way is supported too, aka parsing the view value and setting the model value.

This is very helpful when you want to represent a value in a different unit and let the user interact with it.

Demo

Plnkr demo

About

AngularJS directive that converts to/from metric units using $parser and $formatters

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • JavaScript 84.7%
  • HTML 15.3%