asv-hlps 1.3.17 → 1.3.19

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/lib/cjs/utils.js CHANGED
@@ -623,7 +623,7 @@ const monthStringName = (date, format = "MMM", options) => {
623
623
  return (0, dayjs_1.default)(date).locale("fr").format(format);
624
624
  };
625
625
  exports.monthStringName = monthStringName;
626
- const dateFormatter = (date, format, separator = "/") => {
626
+ const dateFormatter = (date, format = "dmy", separator = "/") => {
627
627
  switch (format) {
628
628
  case "y":
629
629
  return (0, dayjs_1.default)(date).format("YYYY");
@@ -642,7 +642,7 @@ const dateFormatter = (date, format, separator = "/") => {
642
642
  case "mfr-long":
643
643
  return (0, dayjs_1.default)(date).locale("fr").format("MMMM");
644
644
  default:
645
- return (0, dayjs_1.default)(date).format(`DD${separator}MM${separator}YYYY`);
645
+ return (0, dayjs_1.default)(date).format(`DD/MM/YYYY`);
646
646
  // return dayjs(date).format(`YYYY${separator}MM${separator}DD`);
647
647
  }
648
648
  };
package/lib/esm/utils.js CHANGED
@@ -542,7 +542,7 @@ export const monthStringName = (date, format = "MMM", options) => {
542
542
  }
543
543
  return dayjs(date).locale("fr").format(format);
544
544
  };
545
- export const dateFormatter = (date, format, separator = "/") => {
545
+ export const dateFormatter = (date, format = "dmy", separator = "/") => {
546
546
  switch (format) {
547
547
  case "y":
548
548
  return dayjs(date).format("YYYY");
@@ -561,7 +561,7 @@ export const dateFormatter = (date, format, separator = "/") => {
561
561
  case "mfr-long":
562
562
  return dayjs(date).locale("fr").format("MMMM");
563
563
  default:
564
- return dayjs(date).format(`DD${separator}MM${separator}YYYY`);
564
+ return dayjs(date).format(`DD/MM/YYYY`);
565
565
  // return dayjs(date).format(`YYYY${separator}MM${separator}DD`);
566
566
  }
567
567
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "asv-hlps",
3
- "version": "1.3.17",
3
+ "version": "1.3.19",
4
4
  "description": "helpers",
5
5
  "main": "./lib/cjs/index.js",
6
6
  "module": "./lib/esm/index.js",