0.0.3 • Published 7 years ago
new-format.js v0.0.3
new-text (a.k.a. format-text)
String formatting library inspired from Python
Install
$ npm install new-format.js
Usage
format = require('new-format.js')
format('Hello {0}. The weather is currently {1}°.', 'Kitty', '67')
// => Hello Kitty. The weather is currently 67°.
format('Hello {name}, The weather is currently {degree}°', { name:'Kitty', degree: 67 })
// => Hello Kitty. The weather is currently 67°.
0.0.3
7 years ago