1.2.0 • Published 7 years ago
dec2roman v1.2.0
dec2roman
Convert Roman numbers to decimal and back. Supports vinculum for numbers larger than 3999.
Demo at https://www.vperi.com/roman
Installation
Install with npm
$ npm install --save dec2romanAPI
dec2Roman
Converts a {Number} into it's Roman equivalent.
Parameters
xNumber the number to be converted into Roman$1Object (optional, default{})$1.mode(optional, default'ibar')
Returns String The roman equivalent
roman2Dec
Returns the decimal representation of a given Roman number {String}
Parameters
str{String} The roman number to be convertedstrictObjectstrict.strict(optional, defaultfalse)
Returns Number the decimal equivalent
matchAll
Parameters
regex{RegExp}sourceStringaggregator
Returns any