hsu-utils 0.0.15 → 0.0.17
Sign up to get free protection for your applications and to get access to all the features.
- package/LICENSE +1 -1
- package/dist/hsu-utils.js +14 -3
- package/dist/hsu-utils.min.js +1 -1
- package/dist/hsu-utils.min.js.LICENSE.txt +2 -2
- package/es/ArrayIsIncludes/index.d.ts +1 -0
- package/es/ArrayIsIncludes/index.js +8 -0
- package/es/index.d.ts +2 -1
- package/es/index.js +2 -1
- package/lib/ArrayIsIncludes/index.d.ts +1 -0
- package/lib/ArrayIsIncludes/index.js +11 -0
- package/lib/index.d.ts +2 -1
- package/lib/index.js +3 -1
- package/package.json +1 -1
@@ -1,12 +1,12 @@
|
|
1
1
|
/*!
|
2
2
|
*
|
3
|
-
* hsu-utils v0.0.
|
3
|
+
* hsu-utils v0.0.16
|
4
4
|
*
|
5
5
|
* some front-end utils
|
6
6
|
*
|
7
7
|
* MIT License
|
8
8
|
*
|
9
|
-
* Copyright (c) 2023
|
9
|
+
* Copyright (c) 2023 VitaHsu
|
10
10
|
*
|
11
11
|
* Permission is hereby granted, free of charge, to any person obtaining a copy
|
12
12
|
* of this software and associated documentation files (the "Software"), to deal
|
@@ -0,0 +1 @@
|
|
1
|
+
export default function array_is_includes<T>(arr1: Array<T>, arr2: Array<T>): boolean;
|
@@ -0,0 +1,8 @@
|
|
1
|
+
import { Equal } from '..';
|
2
|
+
export default function array_is_includes(arr1, arr2) {
|
3
|
+
const smallArr = arr1.length <= arr2.length ? arr1 : arr2;
|
4
|
+
const largeArr = arr1.length > arr2.length ? arr1 : arr2;
|
5
|
+
return smallArr.every((item) => {
|
6
|
+
return !!largeArr.find((i) => Equal.ValEqual(item, i));
|
7
|
+
});
|
8
|
+
}
|
package/es/index.d.ts
CHANGED
@@ -7,6 +7,7 @@ import ConvertNumbers from './ConvertNumbers';
|
|
7
7
|
import loadImage from './LoadImage';
|
8
8
|
import renderPDF from './RenderPDF';
|
9
9
|
import downloadFile from './DownloadFile';
|
10
|
-
|
10
|
+
import array_is_includes from './ArrayIsIncludes';
|
11
|
+
export { console_table, deepCopy, Equal, Typeof, get_string_width, ConvertNumbers, loadImage, renderPDF, downloadFile, array_is_includes };
|
11
12
|
import { ConsoleData } from './ConsoleTable';
|
12
13
|
export type { ConsoleData };
|
package/es/index.js
CHANGED
@@ -7,4 +7,5 @@ import ConvertNumbers from './ConvertNumbers';
|
|
7
7
|
import loadImage from './LoadImage';
|
8
8
|
import renderPDF from './RenderPDF';
|
9
9
|
import downloadFile from './DownloadFile';
|
10
|
-
|
10
|
+
import array_is_includes from './ArrayIsIncludes';
|
11
|
+
export { console_table, deepCopy, Equal, Typeof, get_string_width, ConvertNumbers, loadImage, renderPDF, downloadFile, array_is_includes };
|
@@ -0,0 +1 @@
|
|
1
|
+
export default function array_is_includes<T>(arr1: Array<T>, arr2: Array<T>): boolean;
|
@@ -0,0 +1,11 @@
|
|
1
|
+
"use strict";
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
3
|
+
var __1 = require("..");
|
4
|
+
function array_is_includes(arr1, arr2) {
|
5
|
+
var smallArr = arr1.length <= arr2.length ? arr1 : arr2;
|
6
|
+
var largeArr = arr1.length > arr2.length ? arr1 : arr2;
|
7
|
+
return smallArr.every(function (item) {
|
8
|
+
return !!largeArr.find(function (i) { return __1.Equal.ValEqual(item, i); });
|
9
|
+
});
|
10
|
+
}
|
11
|
+
exports.default = array_is_includes;
|
package/lib/index.d.ts
CHANGED
@@ -7,6 +7,7 @@ import ConvertNumbers from './ConvertNumbers';
|
|
7
7
|
import loadImage from './LoadImage';
|
8
8
|
import renderPDF from './RenderPDF';
|
9
9
|
import downloadFile from './DownloadFile';
|
10
|
-
|
10
|
+
import array_is_includes from './ArrayIsIncludes';
|
11
|
+
export { console_table, deepCopy, Equal, Typeof, get_string_width, ConvertNumbers, loadImage, renderPDF, downloadFile, array_is_includes };
|
11
12
|
import { ConsoleData } from './ConsoleTable';
|
12
13
|
export type { ConsoleData };
|
package/lib/index.js
CHANGED
@@ -3,7 +3,7 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
3
|
return (mod && mod.__esModule) ? mod : { "default": mod };
|
4
4
|
};
|
5
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
6
|
-
exports.downloadFile = exports.renderPDF = exports.loadImage = exports.ConvertNumbers = exports.get_string_width = exports.Typeof = exports.Equal = exports.deepCopy = exports.console_table = void 0;
|
6
|
+
exports.array_is_includes = exports.downloadFile = exports.renderPDF = exports.loadImage = exports.ConvertNumbers = exports.get_string_width = exports.Typeof = exports.Equal = exports.deepCopy = exports.console_table = void 0;
|
7
7
|
var ConsoleTable_1 = __importDefault(require("./ConsoleTable"));
|
8
8
|
exports.console_table = ConsoleTable_1.default;
|
9
9
|
var DeepCopy_1 = __importDefault(require("./DeepCopy"));
|
@@ -22,3 +22,5 @@ var RenderPDF_1 = __importDefault(require("./RenderPDF"));
|
|
22
22
|
exports.renderPDF = RenderPDF_1.default;
|
23
23
|
var DownloadFile_1 = __importDefault(require("./DownloadFile"));
|
24
24
|
exports.downloadFile = DownloadFile_1.default;
|
25
|
+
var ArrayIsIncludes_1 = __importDefault(require("./ArrayIsIncludes"));
|
26
|
+
exports.array_is_includes = ArrayIsIncludes_1.default;
|