1.0.3 • Published 6 years ago
render-id v1.0.3
render-id
Converts a string pattern to a string by replacing all the '#' to '0' after replacing the next counter number.
Example 1
const renderId = require('render-id');
renderId.render('TES#######',12);
// output : TES0000012Example 2
const renderId = require('render-id');
renderId.render('XYZ#####99##',1234);
// output : XYZ000129934Example 3
const renderId = require('render-id');
renderId.render('ABC##99##',123456);
// output : ABC12993456Example 4
const renderId = require('render-id');
renderId.render('${FY-IN}/##99##',123456);
// output : 2019-2020/12993456Supported Fiscal Years
| Syntax | Description |
|---|---|
| ${FY-IN} | Indian Fiscal Year |
| ${FY-GB} | United Kingdom Fiscal Year |
| ${FY-US} | United States Fiscal Year |