index.js 434 B

1234567891011121314151617
  1. "use strict";
  2. Object.defineProperty(exports, "__esModule", {
  3. value: true
  4. });
  5. exports.default = buildFormatLongFn;
  6. function buildFormatLongFn(args) {
  7. return function (dirtyOptions) {
  8. var options = dirtyOptions || {};
  9. var width = options.width ? String(options.width) : args.defaultWidth;
  10. var format = args.formats[width] || args.formats[args.defaultWidth];
  11. return format;
  12. };
  13. }
  14. module.exports = exports.default;