asv-hlps 1.3.25 → 1.3.26
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 +3 -2
- package/lib/esm/utils.js +3 -2
- package/package.json +4 -4
package/lib/cjs/utils.js
CHANGED
|
@@ -26,7 +26,7 @@ const name = () => { };
|
|
|
26
26
|
/* export const formatFromAndToDate = (fromDate: Date, toDate: Date) => {
|
|
27
27
|
const getFromDate = !fromDate ? new Date() : fromDate;
|
|
28
28
|
const getToDate = !toDate ? fromDate : toDate;
|
|
29
|
-
return
|
|
29
|
+
return dateFormatter(new Date(getFromDate)) + " au " + dateFormatter(new Date(getToDate));
|
|
30
30
|
}; */
|
|
31
31
|
/* export const formatDateYmd = (date: Date | any, separator: string = "") => {
|
|
32
32
|
return formatDateYm(date, separator) + separator + ("0" + date.getUTCDate()).slice(-2);
|
|
@@ -240,7 +240,8 @@ const findFirstSequenceMissing = (arr) => {
|
|
|
240
240
|
};
|
|
241
241
|
exports.findFirstSequenceMissing = findFirstSequenceMissing;
|
|
242
242
|
const deepClone = (obj) => {
|
|
243
|
-
return JSON.parse(JSON.stringify(obj));
|
|
243
|
+
// return JSON.parse(JSON.stringify(obj));
|
|
244
|
+
return lodash_1.default.cloneDeep(obj);
|
|
244
245
|
};
|
|
245
246
|
exports.deepClone = deepClone;
|
|
246
247
|
const removeString = (text, word) => {
|
package/lib/esm/utils.js
CHANGED
|
@@ -19,7 +19,7 @@ const name = () => { };
|
|
|
19
19
|
/* export const formatFromAndToDate = (fromDate: Date, toDate: Date) => {
|
|
20
20
|
const getFromDate = !fromDate ? new Date() : fromDate;
|
|
21
21
|
const getToDate = !toDate ? fromDate : toDate;
|
|
22
|
-
return
|
|
22
|
+
return dateFormatter(new Date(getFromDate)) + " au " + dateFormatter(new Date(getToDate));
|
|
23
23
|
}; */
|
|
24
24
|
/* export const formatDateYmd = (date: Date | any, separator: string = "") => {
|
|
25
25
|
return formatDateYm(date, separator) + separator + ("0" + date.getUTCDate()).slice(-2);
|
|
@@ -210,7 +210,8 @@ export const findFirstSequenceMissing = (arr) => {
|
|
|
210
210
|
return findSequencesMissing(arr)[0];
|
|
211
211
|
};
|
|
212
212
|
export const deepClone = (obj) => {
|
|
213
|
-
return JSON.parse(JSON.stringify(obj));
|
|
213
|
+
// return JSON.parse(JSON.stringify(obj));
|
|
214
|
+
return lodash.cloneDeep(obj);
|
|
214
215
|
};
|
|
215
216
|
export const removeString = (text, word) => {
|
|
216
217
|
return text.toLowerCase().replace(word.toLowerCase(), "") || text;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "asv-hlps",
|
|
3
|
-
"version": "1.3.
|
|
3
|
+
"version": "1.3.26",
|
|
4
4
|
"description": "helpers",
|
|
5
5
|
"main": "./lib/cjs/index.js",
|
|
6
6
|
"module": "./lib/esm/index.js",
|
|
@@ -18,16 +18,16 @@
|
|
|
18
18
|
"devDependencies": {
|
|
19
19
|
"@types/bcryptjs": "^2.4.4",
|
|
20
20
|
"@types/lodash": "^4.14.198",
|
|
21
|
-
"@types/pdfmake": "^0.2.
|
|
21
|
+
"@types/pdfmake": "^0.2.3",
|
|
22
22
|
"@types/randomatic": "^3.1.3",
|
|
23
|
-
"@types/react": "^18.2.
|
|
23
|
+
"@types/react": "^18.2.22",
|
|
24
24
|
"typescript": "^5.2.2"
|
|
25
25
|
},
|
|
26
26
|
"dependencies": {
|
|
27
27
|
"axios": "^1.5.0",
|
|
28
28
|
"bcryptjs": "^2.4.3",
|
|
29
29
|
"classnames": "^2.3.2",
|
|
30
|
-
"dayjs": "^1.11.
|
|
30
|
+
"dayjs": "^1.11.10",
|
|
31
31
|
"jwt-decode": "^3.1.2",
|
|
32
32
|
"lodash": "^4.17.21",
|
|
33
33
|
"pdfmake": "^0.2.7",
|