Sha256: 582b7c7d1a79caa90e13a7e2c52c6fb99237fd8b94c4c50f36646f652cd8e86f
Contents?: true
Size: 480 Bytes
Versions: 21
Compression:
Stored size: 480 Bytes
Contents
// default value format (apply autopadding) // format valueset module.exports = function formatValue(v, options, type){ // no autopadding ? passthrough if (options.autopadding !== true){ return v; } // padding function autopadding(value, length){ return (options.autopaddingChar + value).slice(-length); } switch (type){ case 'percentage': return autopadding(v, 3); default: return v; } }
Version data entries
21 entries across 21 versions & 1 rubygems