Package Exports
- vue-currency-filter
This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (vue-currency-filter) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.
Readme
💵🥂 Vue Currency Filter
Lightweight vue currency filter based on accounting.js
Demo
https://mazipan.github.io/vue-currency-filter/
Download
# NPM
npm install vue-currency-filter
# Yarn
yarn add vue-currency-filterSample Usage
Import in main.js
import VueCurrencyFilter from 'vue-currency-filter'Use Plugins
Vue.use(VueCurrencyFilter)Add Global Configuration
Vue.use(VueCurrencyFilter,
{
symbol : '$',
thousandsSeparator: '.',
fractionCount: 2,
fractionSeparator: ',',
symbolPosition: 'front',
symbolSpacing: true
})Use in View
<span>{{ 20000 | currency}}</span>Add Configuration In Specific Place
<span>
{{ textInput | currency(configSymbol, configSeparator, configFractionCount,
configFractionSeparator, configSymbolPosition, configSymbolSpacing)}}
</span>Available Options
{
symbol: 'string (default : empty string)',
thousandsSeparator: 'string (default : .)',
fractionCount: 'number (default : 0)',
fractionSeparator: 'string (default: ",")',
symbolPosition: 'string (default: front)',
symbolSpacing: 'boolean (default: true)'
}Contributing
If you'd like to contribute, head to the contributing guidelines. Inside you'll find directions for opening issues, coding standards, and notes on development.
Hope this will be useful for you all
Contact Me :
Copyright © 2017 Under MIT License