full-utils 0.0.8 → 1.0.0
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/dist/index.d.ts +41 -36
- package/dist/index.js +46 -36
- package/dist/index.js.map +1 -1
- package/dist/src/from/fromJSON.d.ts +5 -0
- package/dist/src/from/fromJSON.js +71 -0
- package/dist/src/from/fromJSON.js.map +1 -0
- package/dist/src/from/fromTimestamp.d.ts +6 -0
- package/dist/src/from/fromTimestamp.js +8 -0
- package/dist/src/from/fromTimestamp.js.map +1 -0
- package/dist/src/index.d.ts +41 -0
- package/dist/src/index.js +84 -0
- package/dist/src/index.js.map +1 -0
- package/dist/src/is/isArr.d.ts +1 -0
- package/dist/src/is/isArr.js +7 -0
- package/dist/src/is/isArr.js.map +1 -0
- package/dist/src/is/isArrFilled.d.ts +1 -0
- package/dist/{is → src/is}/isArrFilled.js +2 -1
- package/dist/src/is/isArrFilled.js.map +1 -0
- package/dist/src/is/isBool.d.ts +1 -0
- package/dist/src/is/isBool.js.map +1 -0
- package/dist/src/is/isDate.d.ts +1 -0
- package/dist/{is → src/is}/isDate.js +5 -2
- package/dist/src/is/isDate.js.map +1 -0
- package/dist/src/is/isEmail.d.ts +1 -0
- package/dist/{is → src/is}/isEmail.js +2 -1
- package/dist/src/is/isEmail.js.map +1 -0
- package/dist/src/is/isExists.d.ts +1 -0
- package/dist/{is → src/is}/isExists.js +1 -1
- package/dist/src/is/isExists.js.map +1 -0
- package/dist/src/is/isFunc.d.ts +1 -0
- package/dist/{is → src/is}/isFunc.js +1 -1
- package/dist/src/is/isFunc.js.map +1 -0
- package/dist/src/is/isIp.d.ts +1 -0
- package/dist/src/is/isIp.js +13 -0
- package/dist/src/is/isIp.js.map +1 -0
- package/dist/src/is/isMac.d.ts +1 -0
- package/dist/{is → src/is}/isMac.js +1 -2
- package/dist/src/is/isMac.js.map +1 -0
- package/dist/src/is/isNum.d.ts +1 -0
- package/dist/src/is/isNum.js +7 -0
- package/dist/src/is/isNum.js.map +1 -0
- package/dist/src/is/isNumFloat.d.ts +1 -0
- package/dist/{is → src/is}/isNumFloat.js +1 -1
- package/dist/src/is/isNumFloat.js.map +1 -0
- package/dist/src/is/isNumN.d.ts +1 -0
- package/dist/{is → src/is}/isNumN.js +1 -1
- package/dist/src/is/isNumN.js.map +1 -0
- package/dist/src/is/isNumP.d.ts +1 -0
- package/dist/{is → src/is}/isNumP.js +1 -1
- package/dist/src/is/isNumP.js.map +1 -0
- package/dist/src/is/isNumPZ.d.ts +1 -0
- package/dist/{is → src/is}/isNumPZ.js +1 -1
- package/dist/src/is/isNumPZ.js.map +1 -0
- package/dist/src/is/isObj.d.ts +1 -0
- package/dist/src/is/isObj.js +10 -0
- package/dist/src/is/isObj.js.map +1 -0
- package/dist/src/is/isObjFilled.d.ts +1 -0
- package/dist/src/is/isObjFilled.js.map +1 -0
- package/dist/src/is/isPassword.d.ts +10 -0
- package/dist/src/is/isPassword.js +26 -0
- package/dist/src/is/isPassword.js.map +1 -0
- package/dist/src/is/isPhone.d.ts +1 -0
- package/dist/src/is/isPhone.js +35 -0
- package/dist/src/is/isPhone.js.map +1 -0
- package/dist/src/is/isStr.d.ts +1 -0
- package/dist/src/is/isStr.js.map +1 -0
- package/dist/src/is/isStrBool.d.ts +1 -0
- package/dist/src/is/isStrBool.js +12 -0
- package/dist/src/is/isStrBool.js.map +1 -0
- package/dist/src/is/isStrFilled.d.ts +1 -0
- package/dist/{is → src/is}/isStrFilled.js +1 -1
- package/dist/src/is/isStrFilled.js.map +1 -0
- package/dist/src/is/isStrOrderType.d.ts +1 -0
- package/dist/{is → src/is}/isStrOrderType.js +2 -2
- package/dist/src/is/isStrOrderType.js.map +1 -0
- package/dist/src/is/isVar.d.ts +1 -0
- package/dist/src/is/isVar.js +8 -0
- package/dist/src/is/isVar.js.map +1 -0
- package/dist/src/net/netTCP.d.ts +6 -0
- package/dist/src/net/netTCP.js +52 -0
- package/dist/src/net/netTCP.js.map +1 -0
- package/dist/src/to/toArrFuncArgs.d.ts +1 -0
- package/dist/src/to/toArrFuncArgs.js +139 -0
- package/dist/src/to/toArrFuncArgs.js.map +1 -0
- package/dist/src/to/toBool.d.ts +1 -0
- package/dist/src/to/toBool.js +28 -0
- package/dist/src/to/toBool.js.map +1 -0
- package/dist/src/to/toCellDate.js +12 -0
- package/dist/src/to/toCellDate.js.map +1 -0
- package/dist/src/to/toGB.d.ts +1 -0
- package/dist/src/to/toGB.js +47 -0
- package/dist/src/to/toGB.js.map +1 -0
- package/dist/src/to/toGH.js +36 -0
- package/dist/src/to/toGH.js.map +1 -0
- package/dist/src/to/toInetAton.js +18 -0
- package/dist/src/to/toInetAton.js.map +1 -0
- package/dist/{to → src/to}/toInetNtoa.js +4 -3
- package/dist/src/to/toInetNtoa.js.map +1 -0
- package/dist/src/to/toJSON.d.ts +1 -0
- package/dist/src/to/toJSON.js +14 -0
- package/dist/src/to/toJSON.js.map +1 -0
- package/dist/src/to/toLower.d.ts +1 -0
- package/dist/src/to/toLower.js +14 -0
- package/dist/src/to/toLower.js.map +1 -0
- package/dist/src/to/toNum.d.ts +1 -0
- package/dist/src/to/toNum.js +47 -0
- package/dist/src/to/toNum.js.map +1 -0
- package/dist/src/to/toPhone.d.ts +1 -0
- package/dist/src/to/toPhone.js +24 -0
- package/dist/src/to/toPhone.js.map +1 -0
- package/dist/src/to/toPoolName.js.map +1 -0
- package/dist/src/to/toPortions.d.ts +1 -0
- package/dist/src/to/toPortions.js +16 -0
- package/dist/src/to/toPortions.js.map +1 -0
- package/dist/src/to/toTimestamp.js +11 -0
- package/dist/src/to/toTimestamp.js.map +1 -0
- package/dist/tsconfig.build.tsbuildinfo +1 -1
- package/package.json +2 -2
- package/dist/fromJSON.d.ts +0 -1
- package/dist/fromJSON.js +0 -53
- package/dist/fromJSON.js.map +0 -1
- package/dist/is/isArrFilled.d.ts +0 -1
- package/dist/is/isArrFilled.js.map +0 -1
- package/dist/is/isBool.d.ts +0 -1
- package/dist/is/isBool.js.map +0 -1
- package/dist/is/isDate.d.ts +0 -1
- package/dist/is/isDate.js.map +0 -1
- package/dist/is/isEmail.d.ts +0 -1
- package/dist/is/isEmail.js.map +0 -1
- package/dist/is/isExists.d.ts +0 -1
- package/dist/is/isExists.js.map +0 -1
- package/dist/is/isFunc.d.ts +0 -1
- package/dist/is/isFunc.js.map +0 -1
- package/dist/is/isIp.d.ts +0 -1
- package/dist/is/isIp.js +0 -9
- package/dist/is/isIp.js.map +0 -1
- package/dist/is/isMac.d.ts +0 -1
- package/dist/is/isMac.js.map +0 -1
- package/dist/is/isNum.d.ts +0 -1
- package/dist/is/isNum.js +0 -9
- package/dist/is/isNum.js.map +0 -1
- package/dist/is/isNumFloat.d.ts +0 -1
- package/dist/is/isNumFloat.js.map +0 -1
- package/dist/is/isNumN.d.ts +0 -1
- package/dist/is/isNumN.js.map +0 -1
- package/dist/is/isNumP.d.ts +0 -1
- package/dist/is/isNumP.js.map +0 -1
- package/dist/is/isNumPZ.d.ts +0 -1
- package/dist/is/isNumPZ.js.map +0 -1
- package/dist/is/isObj.d.ts +0 -1
- package/dist/is/isObj.js +0 -9
- package/dist/is/isObj.js.map +0 -1
- package/dist/is/isObjFilled.d.ts +0 -1
- package/dist/is/isObjFilled.js.map +0 -1
- package/dist/is/isPassword.d.ts +0 -6
- package/dist/is/isPassword.js +0 -22
- package/dist/is/isPassword.js.map +0 -1
- package/dist/is/isPhone.d.ts +0 -1
- package/dist/is/isPhone.js +0 -16
- package/dist/is/isPhone.js.map +0 -1
- package/dist/is/isStr.d.ts +0 -1
- package/dist/is/isStr.js.map +0 -1
- package/dist/is/isStrBool.d.ts +0 -1
- package/dist/is/isStrBool.js +0 -15
- package/dist/is/isStrBool.js.map +0 -1
- package/dist/is/isStrFilled.d.ts +0 -1
- package/dist/is/isStrFilled.js.map +0 -1
- package/dist/is/isStrOrderType.d.ts +0 -1
- package/dist/is/isStrOrderType.js.map +0 -1
- package/dist/is/isVar.d.ts +0 -1
- package/dist/is/isVar.js +0 -11
- package/dist/is/isVar.js.map +0 -1
- package/dist/net/netTCP.d.ts +0 -1
- package/dist/net/netTCP.js +0 -37
- package/dist/net/netTCP.js.map +0 -1
- package/dist/to/toArrFuncArgs.d.ts +0 -1
- package/dist/to/toArrFuncArgs.js +0 -67
- package/dist/to/toArrFuncArgs.js.map +0 -1
- package/dist/to/toBool.d.ts +0 -1
- package/dist/to/toBool.js +0 -23
- package/dist/to/toBool.js.map +0 -1
- package/dist/to/toCellDate.js +0 -26
- package/dist/to/toCellDate.js.map +0 -1
- package/dist/to/toGB.d.ts +0 -1
- package/dist/to/toGB.js +0 -30
- package/dist/to/toGB.js.map +0 -1
- package/dist/to/toGH.js +0 -38
- package/dist/to/toGH.js.map +0 -1
- package/dist/to/toInetAton.js +0 -14
- package/dist/to/toInetAton.js.map +0 -1
- package/dist/to/toInetNtoa.js.map +0 -1
- package/dist/to/toNum.d.ts +0 -1
- package/dist/to/toNum.js +0 -40
- package/dist/to/toNum.js.map +0 -1
- package/dist/to/toPoolName.js.map +0 -1
- package/dist/to/toPortions.d.ts +0 -1
- package/dist/to/toPortions.js +0 -14
- package/dist/to/toPortions.js.map +0 -1
- package/dist/to/toTimestamp.js +0 -22
- package/dist/to/toTimestamp.js.map +0 -1
- /package/dist/{is → src/is}/isBool.js +0 -0
- /package/dist/{is → src/is}/isObjFilled.js +0 -0
- /package/dist/{is → src/is}/isStr.js +0 -0
- /package/dist/{to → src/to}/toCellDate.d.ts +0 -0
- /package/dist/{to → src/to}/toGH.d.ts +0 -0
- /package/dist/{to → src/to}/toInetAton.d.ts +0 -0
- /package/dist/{to → src/to}/toInetNtoa.d.ts +0 -0
- /package/dist/{to → src/to}/toPoolName.d.ts +0 -0
- /package/dist/{to → src/to}/toPoolName.js +0 -0
- /package/dist/{to → src/to}/toTimestamp.d.ts +0 -0
package/dist/index.d.ts
CHANGED
|
@@ -1,36 +1,41 @@
|
|
|
1
|
-
import { fromJSON } from './fromJSON';
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
6
|
-
import {
|
|
7
|
-
import {
|
|
8
|
-
import {
|
|
9
|
-
import {
|
|
10
|
-
import {
|
|
11
|
-
import {
|
|
12
|
-
import {
|
|
13
|
-
import {
|
|
14
|
-
import {
|
|
15
|
-
import {
|
|
16
|
-
import {
|
|
17
|
-
import {
|
|
18
|
-
import {
|
|
19
|
-
import {
|
|
20
|
-
import {
|
|
21
|
-
import {
|
|
22
|
-
import {
|
|
23
|
-
import {
|
|
24
|
-
import {
|
|
25
|
-
import {
|
|
26
|
-
import {
|
|
27
|
-
import {
|
|
28
|
-
import {
|
|
29
|
-
import {
|
|
30
|
-
import {
|
|
31
|
-
import {
|
|
32
|
-
import {
|
|
33
|
-
import {
|
|
34
|
-
import {
|
|
35
|
-
import {
|
|
36
|
-
|
|
1
|
+
import { fromJSON } from './src/from/fromJSON';
|
|
2
|
+
import { fromTimestamp } from './src/from/fromTimestamp';
|
|
3
|
+
import { isArr } from './src/is/isArr';
|
|
4
|
+
import { isArrFilled } from './src/is/isArrFilled';
|
|
5
|
+
import { isBool } from './src/is/isBool';
|
|
6
|
+
import { isDate } from './src/is/isDate';
|
|
7
|
+
import { isEmail } from './src/is/isEmail';
|
|
8
|
+
import { isExists } from './src/is/isExists';
|
|
9
|
+
import { isFunc } from './src/is/isFunc';
|
|
10
|
+
import { isIp } from './src/is/isIp';
|
|
11
|
+
import { isMac } from './src/is/isMac';
|
|
12
|
+
import { isNum } from './src/is/isNum';
|
|
13
|
+
import { isNumFloat } from './src/is/isNumFloat';
|
|
14
|
+
import { isNumN } from './src/is/isNumN';
|
|
15
|
+
import { isNumP } from './src/is/isNumP';
|
|
16
|
+
import { isNumPZ } from './src/is/isNumPZ';
|
|
17
|
+
import { isObj } from './src/is/isObj';
|
|
18
|
+
import { isObjFilled } from './src/is/isObjFilled';
|
|
19
|
+
import { isPassword } from './src/is/isPassword';
|
|
20
|
+
import { isPhone } from './src/is/isPhone';
|
|
21
|
+
import { isStr } from './src/is/isStr';
|
|
22
|
+
import { isStrBool } from './src/is/isStrBool';
|
|
23
|
+
import { isStrFilled } from './src/is/isStrFilled';
|
|
24
|
+
import { isStrOrderType } from './src/is/isStrOrderType';
|
|
25
|
+
import { isVar } from './src/is/isVar';
|
|
26
|
+
import { toBool } from './src/to/toBool';
|
|
27
|
+
import { toCellDate } from './src/to/toCellDate';
|
|
28
|
+
import { toGB } from './src/to/toGB';
|
|
29
|
+
import { toGH } from './src/to/toGH';
|
|
30
|
+
import { toInetAton } from './src/to/toInetAton';
|
|
31
|
+
import { toInetNtoa } from './src/to/toInetNtoa';
|
|
32
|
+
import { toNum } from './src/to/toNum';
|
|
33
|
+
import { toPortions } from './src/to/toPortions';
|
|
34
|
+
import { toTimestamp } from './src/to/toTimestamp';
|
|
35
|
+
import { toArrFuncArgs } from './src/to/toArrFuncArgs';
|
|
36
|
+
import { toJSON } from './src/to/toJSON';
|
|
37
|
+
import { toPhone } from './src/to/toPhone';
|
|
38
|
+
import { toLower } from './src/to/toLower';
|
|
39
|
+
import { toPoolName } from './src/to/toPoolName';
|
|
40
|
+
import { netTCP } from './src/net/netTCP';
|
|
41
|
+
export { fromJSON, fromTimestamp, isArr, isArrFilled, isBool, isDate, isEmail, isExists, isFunc, isIp, isMac, isNum, isNumFloat, isNumN, isNumP, isNumPZ, isObj, isObjFilled, isPassword, isPhone, isStr, isStrBool, isStrFilled, isStrOrderType, isVar, toBool, toCellDate, toGB, toGH, toInetAton, toInetNtoa, toNum, toPortions, toTimestamp, toArrFuncArgs, toJSON, toPhone, toLower, toPoolName, netTCP, };
|
package/dist/index.js
CHANGED
|
@@ -1,74 +1,84 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.netTCP = exports.toPoolName = exports.toArrFuncArgs = exports.toTimestamp = exports.toPortions = exports.toNum = exports.toInetNtoa = exports.toInetAton = exports.toGH = exports.toGB = exports.toCellDate = exports.toBool = exports.isVar = exports.isStrOrderType = exports.isStrFilled = exports.isStrBool = exports.isStr = exports.isPhone = exports.isPassword = exports.isObjFilled = exports.isObj = exports.isNumPZ = exports.isNumP = exports.isNumN = exports.isNumFloat = exports.isNum = exports.isMac = exports.isIp = exports.isFunc = exports.isExists = exports.isEmail = exports.isDate = exports.isBool = exports.isArrFilled = exports.fromJSON = void 0;
|
|
4
|
-
const fromJSON_1 = require("./fromJSON");
|
|
3
|
+
exports.netTCP = exports.toPoolName = exports.toLower = exports.toPhone = exports.toJSON = exports.toArrFuncArgs = exports.toTimestamp = exports.toPortions = exports.toNum = exports.toInetNtoa = exports.toInetAton = exports.toGH = exports.toGB = exports.toCellDate = exports.toBool = exports.isVar = exports.isStrOrderType = exports.isStrFilled = exports.isStrBool = exports.isStr = exports.isPhone = exports.isPassword = exports.isObjFilled = exports.isObj = exports.isNumPZ = exports.isNumP = exports.isNumN = exports.isNumFloat = exports.isNum = exports.isMac = exports.isIp = exports.isFunc = exports.isExists = exports.isEmail = exports.isDate = exports.isBool = exports.isArrFilled = exports.isArr = exports.fromTimestamp = exports.fromJSON = void 0;
|
|
4
|
+
const fromJSON_1 = require("./src/from/fromJSON");
|
|
5
5
|
Object.defineProperty(exports, "fromJSON", { enumerable: true, get: function () { return fromJSON_1.fromJSON; } });
|
|
6
|
-
const
|
|
6
|
+
const fromTimestamp_1 = require("./src/from/fromTimestamp");
|
|
7
|
+
Object.defineProperty(exports, "fromTimestamp", { enumerable: true, get: function () { return fromTimestamp_1.fromTimestamp; } });
|
|
8
|
+
const isArr_1 = require("./src/is/isArr");
|
|
9
|
+
Object.defineProperty(exports, "isArr", { enumerable: true, get: function () { return isArr_1.isArr; } });
|
|
10
|
+
const isArrFilled_1 = require("./src/is/isArrFilled");
|
|
7
11
|
Object.defineProperty(exports, "isArrFilled", { enumerable: true, get: function () { return isArrFilled_1.isArrFilled; } });
|
|
8
|
-
const isBool_1 = require("./is/isBool");
|
|
12
|
+
const isBool_1 = require("./src/is/isBool");
|
|
9
13
|
Object.defineProperty(exports, "isBool", { enumerable: true, get: function () { return isBool_1.isBool; } });
|
|
10
|
-
const isDate_1 = require("./is/isDate");
|
|
14
|
+
const isDate_1 = require("./src/is/isDate");
|
|
11
15
|
Object.defineProperty(exports, "isDate", { enumerable: true, get: function () { return isDate_1.isDate; } });
|
|
12
|
-
const isEmail_1 = require("./is/isEmail");
|
|
16
|
+
const isEmail_1 = require("./src/is/isEmail");
|
|
13
17
|
Object.defineProperty(exports, "isEmail", { enumerable: true, get: function () { return isEmail_1.isEmail; } });
|
|
14
|
-
const isExists_1 = require("./is/isExists");
|
|
18
|
+
const isExists_1 = require("./src/is/isExists");
|
|
15
19
|
Object.defineProperty(exports, "isExists", { enumerable: true, get: function () { return isExists_1.isExists; } });
|
|
16
|
-
const isFunc_1 = require("./is/isFunc");
|
|
20
|
+
const isFunc_1 = require("./src/is/isFunc");
|
|
17
21
|
Object.defineProperty(exports, "isFunc", { enumerable: true, get: function () { return isFunc_1.isFunc; } });
|
|
18
|
-
const isIp_1 = require("./is/isIp");
|
|
22
|
+
const isIp_1 = require("./src/is/isIp");
|
|
19
23
|
Object.defineProperty(exports, "isIp", { enumerable: true, get: function () { return isIp_1.isIp; } });
|
|
20
|
-
const isMac_1 = require("./is/isMac");
|
|
24
|
+
const isMac_1 = require("./src/is/isMac");
|
|
21
25
|
Object.defineProperty(exports, "isMac", { enumerable: true, get: function () { return isMac_1.isMac; } });
|
|
22
|
-
const isNum_1 = require("./is/isNum");
|
|
26
|
+
const isNum_1 = require("./src/is/isNum");
|
|
23
27
|
Object.defineProperty(exports, "isNum", { enumerable: true, get: function () { return isNum_1.isNum; } });
|
|
24
|
-
const isNumFloat_1 = require("./is/isNumFloat");
|
|
28
|
+
const isNumFloat_1 = require("./src/is/isNumFloat");
|
|
25
29
|
Object.defineProperty(exports, "isNumFloat", { enumerable: true, get: function () { return isNumFloat_1.isNumFloat; } });
|
|
26
|
-
const isNumN_1 = require("./is/isNumN");
|
|
30
|
+
const isNumN_1 = require("./src/is/isNumN");
|
|
27
31
|
Object.defineProperty(exports, "isNumN", { enumerable: true, get: function () { return isNumN_1.isNumN; } });
|
|
28
|
-
const isNumP_1 = require("./is/isNumP");
|
|
32
|
+
const isNumP_1 = require("./src/is/isNumP");
|
|
29
33
|
Object.defineProperty(exports, "isNumP", { enumerable: true, get: function () { return isNumP_1.isNumP; } });
|
|
30
|
-
const isNumPZ_1 = require("./is/isNumPZ");
|
|
34
|
+
const isNumPZ_1 = require("./src/is/isNumPZ");
|
|
31
35
|
Object.defineProperty(exports, "isNumPZ", { enumerable: true, get: function () { return isNumPZ_1.isNumPZ; } });
|
|
32
|
-
const isObj_1 = require("./is/isObj");
|
|
36
|
+
const isObj_1 = require("./src/is/isObj");
|
|
33
37
|
Object.defineProperty(exports, "isObj", { enumerable: true, get: function () { return isObj_1.isObj; } });
|
|
34
|
-
const isObjFilled_1 = require("./is/isObjFilled");
|
|
38
|
+
const isObjFilled_1 = require("./src/is/isObjFilled");
|
|
35
39
|
Object.defineProperty(exports, "isObjFilled", { enumerable: true, get: function () { return isObjFilled_1.isObjFilled; } });
|
|
36
|
-
const isPassword_1 = require("./is/isPassword");
|
|
40
|
+
const isPassword_1 = require("./src/is/isPassword");
|
|
37
41
|
Object.defineProperty(exports, "isPassword", { enumerable: true, get: function () { return isPassword_1.isPassword; } });
|
|
38
|
-
const isPhone_1 = require("./is/isPhone");
|
|
42
|
+
const isPhone_1 = require("./src/is/isPhone");
|
|
39
43
|
Object.defineProperty(exports, "isPhone", { enumerable: true, get: function () { return isPhone_1.isPhone; } });
|
|
40
|
-
const isStr_1 = require("./is/isStr");
|
|
44
|
+
const isStr_1 = require("./src/is/isStr");
|
|
41
45
|
Object.defineProperty(exports, "isStr", { enumerable: true, get: function () { return isStr_1.isStr; } });
|
|
42
|
-
const isStrBool_1 = require("./is/isStrBool");
|
|
46
|
+
const isStrBool_1 = require("./src/is/isStrBool");
|
|
43
47
|
Object.defineProperty(exports, "isStrBool", { enumerable: true, get: function () { return isStrBool_1.isStrBool; } });
|
|
44
|
-
const isStrFilled_1 = require("./is/isStrFilled");
|
|
48
|
+
const isStrFilled_1 = require("./src/is/isStrFilled");
|
|
45
49
|
Object.defineProperty(exports, "isStrFilled", { enumerable: true, get: function () { return isStrFilled_1.isStrFilled; } });
|
|
46
|
-
const isStrOrderType_1 = require("./is/isStrOrderType");
|
|
50
|
+
const isStrOrderType_1 = require("./src/is/isStrOrderType");
|
|
47
51
|
Object.defineProperty(exports, "isStrOrderType", { enumerable: true, get: function () { return isStrOrderType_1.isStrOrderType; } });
|
|
48
|
-
const isVar_1 = require("./is/isVar");
|
|
52
|
+
const isVar_1 = require("./src/is/isVar");
|
|
49
53
|
Object.defineProperty(exports, "isVar", { enumerable: true, get: function () { return isVar_1.isVar; } });
|
|
50
|
-
const toBool_1 = require("./to/toBool");
|
|
54
|
+
const toBool_1 = require("./src/to/toBool");
|
|
51
55
|
Object.defineProperty(exports, "toBool", { enumerable: true, get: function () { return toBool_1.toBool; } });
|
|
52
|
-
const toCellDate_1 = require("./to/toCellDate");
|
|
56
|
+
const toCellDate_1 = require("./src/to/toCellDate");
|
|
53
57
|
Object.defineProperty(exports, "toCellDate", { enumerable: true, get: function () { return toCellDate_1.toCellDate; } });
|
|
54
|
-
const toGB_1 = require("./to/toGB");
|
|
58
|
+
const toGB_1 = require("./src/to/toGB");
|
|
55
59
|
Object.defineProperty(exports, "toGB", { enumerable: true, get: function () { return toGB_1.toGB; } });
|
|
56
|
-
const toGH_1 = require("./to/toGH");
|
|
60
|
+
const toGH_1 = require("./src/to/toGH");
|
|
57
61
|
Object.defineProperty(exports, "toGH", { enumerable: true, get: function () { return toGH_1.toGH; } });
|
|
58
|
-
const toInetAton_1 = require("./to/toInetAton");
|
|
62
|
+
const toInetAton_1 = require("./src/to/toInetAton");
|
|
59
63
|
Object.defineProperty(exports, "toInetAton", { enumerable: true, get: function () { return toInetAton_1.toInetAton; } });
|
|
60
|
-
const toInetNtoa_1 = require("./to/toInetNtoa");
|
|
64
|
+
const toInetNtoa_1 = require("./src/to/toInetNtoa");
|
|
61
65
|
Object.defineProperty(exports, "toInetNtoa", { enumerable: true, get: function () { return toInetNtoa_1.toInetNtoa; } });
|
|
62
|
-
const toNum_1 = require("./to/toNum");
|
|
66
|
+
const toNum_1 = require("./src/to/toNum");
|
|
63
67
|
Object.defineProperty(exports, "toNum", { enumerable: true, get: function () { return toNum_1.toNum; } });
|
|
64
|
-
const toPortions_1 = require("./to/toPortions");
|
|
68
|
+
const toPortions_1 = require("./src/to/toPortions");
|
|
65
69
|
Object.defineProperty(exports, "toPortions", { enumerable: true, get: function () { return toPortions_1.toPortions; } });
|
|
66
|
-
const toTimestamp_1 = require("./to/toTimestamp");
|
|
70
|
+
const toTimestamp_1 = require("./src/to/toTimestamp");
|
|
67
71
|
Object.defineProperty(exports, "toTimestamp", { enumerable: true, get: function () { return toTimestamp_1.toTimestamp; } });
|
|
68
|
-
const toArrFuncArgs_1 = require("./to/toArrFuncArgs");
|
|
72
|
+
const toArrFuncArgs_1 = require("./src/to/toArrFuncArgs");
|
|
69
73
|
Object.defineProperty(exports, "toArrFuncArgs", { enumerable: true, get: function () { return toArrFuncArgs_1.toArrFuncArgs; } });
|
|
70
|
-
const
|
|
74
|
+
const toJSON_1 = require("./src/to/toJSON");
|
|
75
|
+
Object.defineProperty(exports, "toJSON", { enumerable: true, get: function () { return toJSON_1.toJSON; } });
|
|
76
|
+
const toPhone_1 = require("./src/to/toPhone");
|
|
77
|
+
Object.defineProperty(exports, "toPhone", { enumerable: true, get: function () { return toPhone_1.toPhone; } });
|
|
78
|
+
const toLower_1 = require("./src/to/toLower");
|
|
79
|
+
Object.defineProperty(exports, "toLower", { enumerable: true, get: function () { return toLower_1.toLower; } });
|
|
80
|
+
const toPoolName_1 = require("./src/to/toPoolName");
|
|
71
81
|
Object.defineProperty(exports, "toPoolName", { enumerable: true, get: function () { return toPoolName_1.toPoolName; } });
|
|
72
|
-
const netTCP_1 = require("./net/netTCP");
|
|
82
|
+
const netTCP_1 = require("./src/net/netTCP");
|
|
73
83
|
Object.defineProperty(exports, "netTCP", { enumerable: true, get: function () { return netTCP_1.netTCP; } });
|
|
74
84
|
//# sourceMappingURL=index.js.map
|
package/dist/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../index.ts"],"names":[],"mappings":";;;AAAA,kDAA+C;AA0C9C,yFA1CQ,mBAAQ,OA0CR;AAzCT,4DAAyD;AA0CxD,8FA1CQ,6BAAa,OA0CR;AAzCd,0CAAuC;AA0CtC,sFA1CQ,aAAK,OA0CR;AAzCN,sDAAmD;AA0ClD,4FA1CQ,yBAAW,OA0CR;AAzCZ,4CAAyC;AA0CxC,uFA1CQ,eAAM,OA0CR;AAzCP,4CAAyC;AA0CxC,uFA1CQ,eAAM,OA0CR;AAzCP,8CAA2C;AA0C1C,wFA1CQ,iBAAO,OA0CR;AAzCR,gDAA6C;AA0C5C,yFA1CQ,mBAAQ,OA0CR;AAzCT,4CAAyC;AA0CxC,uFA1CQ,eAAM,OA0CR;AAzCP,wCAAqC;AA0CpC,qFA1CQ,WAAI,OA0CR;AAzCL,0CAAuC;AA0CtC,sFA1CQ,aAAK,OA0CR;AAzCN,0CAAuC;AA0CtC,sFA1CQ,aAAK,OA0CR;AAzCN,oDAAiD;AA0ChD,2FA1CQ,uBAAU,OA0CR;AAzCX,4CAAyC;AA0CxC,uFA1CQ,eAAM,OA0CR;AAzCP,4CAAyC;AA0CxC,uFA1CQ,eAAM,OA0CR;AAzCP,8CAA2C;AA0C1C,wFA1CQ,iBAAO,OA0CR;AAzCR,0CAAuC;AA0CtC,sFA1CQ,aAAK,OA0CR;AAzCN,sDAAmD;AA0ClD,4FA1CQ,yBAAW,OA0CR;AAzCZ,oDAAiD;AA0ChD,2FA1CQ,uBAAU,OA0CR;AAzCX,8CAA2C;AA0C1C,wFA1CQ,iBAAO,OA0CR;AAzCR,0CAAuC;AA0CtC,sFA1CQ,aAAK,OA0CR;AAzCN,kDAA+C;AA0C9C,0FA1CQ,qBAAS,OA0CR;AAzCV,sDAAmD;AA0ClD,4FA1CQ,yBAAW,OA0CR;AAzCZ,4DAAyD;AA0CxD,+FA1CQ,+BAAc,OA0CR;AAzCf,0CAAuC;AA0CtC,sFA1CQ,aAAK,OA0CR;AAzCN,4CAAyC;AA0CxC,uFA1CQ,eAAM,OA0CR;AAzCP,oDAAiD;AA0ChD,2FA1CQ,uBAAU,OA0CR;AAzCX,wCAAqC;AA0CpC,qFA1CQ,WAAI,OA0CR;AAzCL,wCAAqC;AA0CpC,qFA1CQ,WAAI,OA0CR;AAzCL,oDAAiD;AA0ChD,2FA1CQ,uBAAU,OA0CR;AAzCX,oDAAiD;AA0ChD,2FA1CQ,uBAAU,OA0CR;AAzCX,0CAAuC;AA0CtC,sFA1CQ,aAAK,OA0CR;AAzCN,oDAAiD;AA0ChD,2FA1CQ,uBAAU,OA0CR;AAzCX,sDAAmD;AA0ClD,4FA1CQ,yBAAW,OA0CR;AAzCZ,0DAAuD;AA0CtD,8FA1CQ,6BAAa,OA0CR;AAzCd,4CAAyC;AA0CxC,uFA1CQ,eAAM,OA0CR;AAzCP,8CAA2C;AA0C1C,wFA1CQ,iBAAO,OA0CR;AAzCR,8CAA2C;AA0C1C,wFA1CQ,iBAAO,OA0CR;AAzCR,oDAAiD;AA0ChD,2FA1CQ,uBAAU,OA0CR;AAzCX,6CAA0C;AA0CzC,uFA1CQ,eAAM,OA0CR"}
|
|
@@ -0,0 +1,71 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.fromJSON = fromJSON;
|
|
4
|
+
const isArrFilled_1 = require("../is/isArrFilled");
|
|
5
|
+
const isArr_1 = require("../is/isArr");
|
|
6
|
+
const isObjFilled_1 = require("../is/isObjFilled");
|
|
7
|
+
const isObj_1 = require("../is/isObj");
|
|
8
|
+
const isStrFilled_1 = require("../is/isStrFilled");
|
|
9
|
+
const isNum_1 = require("../is/isNum");
|
|
10
|
+
const isBool_1 = require("../is/isBool");
|
|
11
|
+
const QUOTED_RE = /^(['"`])([\s\S]*)\1$/;
|
|
12
|
+
function tryParseJSON(str) {
|
|
13
|
+
try {
|
|
14
|
+
return { ok: true, value: JSON.parse(str) };
|
|
15
|
+
}
|
|
16
|
+
catch (err) {
|
|
17
|
+
}
|
|
18
|
+
return { ok: false };
|
|
19
|
+
}
|
|
20
|
+
function parseStringLike(s, allowString) {
|
|
21
|
+
const trimmed = s.trim();
|
|
22
|
+
const pr = tryParseJSON(trimmed);
|
|
23
|
+
if (pr.ok) {
|
|
24
|
+
return pr.value;
|
|
25
|
+
}
|
|
26
|
+
const m = QUOTED_RE.exec(trimmed);
|
|
27
|
+
if (m) {
|
|
28
|
+
return m[2];
|
|
29
|
+
}
|
|
30
|
+
return allowString ? trimmed : null;
|
|
31
|
+
}
|
|
32
|
+
function fromJSON(value, allowString = false) {
|
|
33
|
+
if (value === null || (0, isNum_1.isNum)(value) || (0, isBool_1.isBool)(value)) {
|
|
34
|
+
return value;
|
|
35
|
+
}
|
|
36
|
+
if ((0, isArrFilled_1.isArrFilled)(value)) {
|
|
37
|
+
const arr = value;
|
|
38
|
+
const out = [];
|
|
39
|
+
for (const item of arr) {
|
|
40
|
+
if ((0, isStrFilled_1.isStrFilled)(item)) {
|
|
41
|
+
out.push(parseStringLike(String(item), allowString));
|
|
42
|
+
}
|
|
43
|
+
else {
|
|
44
|
+
out.push(item);
|
|
45
|
+
}
|
|
46
|
+
}
|
|
47
|
+
return out;
|
|
48
|
+
}
|
|
49
|
+
if ((0, isObjFilled_1.isObjFilled)(value)) {
|
|
50
|
+
const src = value;
|
|
51
|
+
const out = {};
|
|
52
|
+
for (const key of Object.keys(src)) {
|
|
53
|
+
const v = src[key];
|
|
54
|
+
if ((0, isStrFilled_1.isStrFilled)(v)) {
|
|
55
|
+
out[key] = parseStringLike(String(v), allowString);
|
|
56
|
+
}
|
|
57
|
+
else {
|
|
58
|
+
out[key] = v;
|
|
59
|
+
}
|
|
60
|
+
}
|
|
61
|
+
return out;
|
|
62
|
+
}
|
|
63
|
+
if ((0, isArr_1.isArr)(value) || (0, isObj_1.isObj)(value)) {
|
|
64
|
+
return value;
|
|
65
|
+
}
|
|
66
|
+
if ((0, isStrFilled_1.isStrFilled)(value)) {
|
|
67
|
+
return parseStringLike(String(value), allowString);
|
|
68
|
+
}
|
|
69
|
+
return null;
|
|
70
|
+
}
|
|
71
|
+
//# sourceMappingURL=fromJSON.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"fromJSON.js","sourceRoot":"","sources":["../../../src/from/fromJSON.ts"],"names":[],"mappings":";;AA0CA,4BAyCC;AAnFD,mDAAgD;AAChD,uCAAoC;AACpC,mDAAgD;AAChD,uCAAoC;AACpC,mDAAgD;AAChD,uCAAoC;AACpC,yCAAsC;AAUtC,MAAM,SAAS,GAAG,sBAAsB,CAAC;AAEzC,SAAS,YAAY,CAAC,GAAW;IAChC,IAAI,CAAC;QACJ,OAAO,EAAE,EAAE,EAAE,IAAI,EAAE,KAAK,EAAE,IAAI,CAAC,KAAK,CAAC,GAAG,CAAa,EAAE,CAAC;IACzD,CAAC;IACD,OAAO,GAAG,EAAE,CAAC;IACb,CAAC;IACD,OAAO,EAAE,EAAE,EAAE,KAAK,EAAE,CAAC;AACtB,CAAC;AAED,SAAS,eAAe,CAAC,CAAS,EAAE,WAAoB;IACvD,MAAM,OAAO,GAAG,CAAC,CAAC,IAAI,EAAE,CAAC;IACzB,MAAM,EAAE,GAAG,YAAY,CAAC,OAAO,CAAC,CAAC;IAEjC,IAAI,EAAE,CAAC,EAAE,EAAE,CAAC;QACX,OAAO,EAAE,CAAC,KAAK,CAAC;IACjB,CAAC;IACD,MAAM,CAAC,GAAG,SAAS,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC;IAElC,IAAI,CAAC,EAAE,CAAC;QACP,OAAO,CAAC,CAAC,CAAC,CAAa,CAAC;IACzB,CAAC;IACD,OAAO,WAAW,CAAC,CAAC,CAAE,OAAoB,CAAC,CAAC,CAAC,IAAI,CAAC;AACnD,CAAC;AAED,SAAgB,QAAQ,CAAe,KAAc,EAAE,WAAW,GAAG,KAAK;IACzE,IAAI,KAAK,KAAK,IAAI,IAAI,IAAA,aAAK,EAAC,KAAK,CAAC,IAAI,IAAA,eAAM,EAAC,KAAK,CAAC,EAAE,CAAC;QACrD,OAAO,KAAqB,CAAC;IAC9B,CAAC;IACD,IAAI,IAAA,yBAAW,EAAC,KAAK,CAAC,EAAE,CAAC;QACxB,MAAM,GAAG,GAAG,KAA+B,CAAC;QAC5C,MAAM,GAAG,GAAe,EAAE,CAAC;QAE3B,KAAK,MAAM,IAAI,IAAI,GAAG,EAAE,CAAC;YACxB,IAAI,IAAA,yBAAW,EAAC,IAAI,CAAC,EAAE,CAAC;gBACvB,GAAG,CAAC,IAAI,CAAC,eAAe,CAAC,MAAM,CAAC,IAAI,CAAC,EAAE,WAAW,CAAC,CAAC,CAAC;YACtD,CAAC;iBACI,CAAC;gBACL,GAAG,CAAC,IAAI,CAAC,IAAgB,CAAC,CAAC;YAC5B,CAAC;QACF,CAAC;QACD,OAAO,GAAmB,CAAC;IAC5B,CAAC;IACD,IAAI,IAAA,yBAAW,EAAC,KAAK,CAAC,EAAE,CAAC;QACxB,MAAM,GAAG,GAAG,KAAgC,CAAC;QAC7C,MAAM,GAAG,GAA6B,EAAE,CAAC;QAEzC,KAAK,MAAM,GAAG,IAAI,MAAM,CAAC,IAAI,CAAC,GAAG,CAAC,EAAE,CAAC;YACpC,MAAM,CAAC,GAAG,GAAG,CAAC,GAAG,CAAC,CAAC;YAEnB,IAAI,IAAA,yBAAW,EAAC,CAAC,CAAC,EAAE,CAAC;gBACpB,GAAG,CAAC,GAAG,CAAC,GAAG,eAAe,CAAC,MAAM,CAAC,CAAC,CAAC,EAAE,WAAW,CAAC,CAAC;YACpD,CAAC;iBACI,CAAC;gBACL,GAAG,CAAC,GAAG,CAAC,GAAG,CAAa,CAAC;YAC1B,CAAC;QACF,CAAC;QACD,OAAO,GAAmB,CAAC;IAC5B,CAAC;IACD,IAAI,IAAA,aAAK,EAAC,KAAK,CAAC,IAAI,IAAA,aAAK,EAAC,KAAK,CAAC,EAAE,CAAC;QAClC,OAAO,KAAqB,CAAC;IAC9B,CAAC;IACD,IAAI,IAAA,yBAAW,EAAC,KAAK,CAAC,EAAE,CAAC;QACxB,OAAO,eAAe,CAAC,MAAM,CAAC,KAAK,CAAC,EAAE,WAAW,CAAiB,CAAC;IACpE,CAAC;IACD,OAAO,IAAI,CAAC;AACb,CAAC"}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.fromTimestamp = fromTimestamp;
|
|
4
|
+
function fromTimestamp(parts) {
|
|
5
|
+
const { days = 0, hours = 0, minutes = 0, seconds = 0 } = parts;
|
|
6
|
+
return days * 86400 + hours * 3600 + minutes * 60 + seconds;
|
|
7
|
+
}
|
|
8
|
+
//# sourceMappingURL=fromTimestamp.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"fromTimestamp.js","sourceRoot":"","sources":["../../../src/from/fromTimestamp.ts"],"names":[],"mappings":";;AACA,sCASC;AATD,SAAgB,aAAa,CAAC,KAK7B;IACA,MAAM,EAAE,IAAI,GAAG,CAAC,EAAE,KAAK,GAAG,CAAC,EAAE,OAAO,GAAG,CAAC,EAAE,OAAO,GAAG,CAAC,EAAE,GAAG,KAAK,CAAC;IAEhE,OAAO,IAAI,GAAG,KAAK,GAAG,KAAK,GAAG,IAAI,GAAG,OAAO,GAAG,EAAE,GAAG,OAAO,CAAC;AAC7D,CAAC"}
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
import { fromJSON } from './from/fromJSON';
|
|
2
|
+
import { fromTimestamp } from './from/fromTimestamp';
|
|
3
|
+
import { isArr } from './is/isArr';
|
|
4
|
+
import { isArrFilled } from './is/isArrFilled';
|
|
5
|
+
import { isBool } from './is/isBool';
|
|
6
|
+
import { isDate } from './is/isDate';
|
|
7
|
+
import { isEmail } from './is/isEmail';
|
|
8
|
+
import { isExists } from './is/isExists';
|
|
9
|
+
import { isFunc } from './is/isFunc';
|
|
10
|
+
import { isIp } from './is/isIp';
|
|
11
|
+
import { isMac } from './is/isMac';
|
|
12
|
+
import { isNum } from './is/isNum';
|
|
13
|
+
import { isNumFloat } from './is/isNumFloat';
|
|
14
|
+
import { isNumN } from './is/isNumN';
|
|
15
|
+
import { isNumP } from './is/isNumP';
|
|
16
|
+
import { isNumPZ } from './is/isNumPZ';
|
|
17
|
+
import { isObj } from './is/isObj';
|
|
18
|
+
import { isObjFilled } from './is/isObjFilled';
|
|
19
|
+
import { isPassword } from './is/isPassword';
|
|
20
|
+
import { isPhone } from './is/isPhone';
|
|
21
|
+
import { isStr } from './is/isStr';
|
|
22
|
+
import { isStrBool } from './is/isStrBool';
|
|
23
|
+
import { isStrFilled } from './is/isStrFilled';
|
|
24
|
+
import { isStrOrderType } from './is/isStrOrderType';
|
|
25
|
+
import { isVar } from './is/isVar';
|
|
26
|
+
import { toBool } from './to/toBool';
|
|
27
|
+
import { toCellDate } from './to/toCellDate';
|
|
28
|
+
import { toGB } from './to/toGB';
|
|
29
|
+
import { toGH } from './to/toGH';
|
|
30
|
+
import { toInetAton } from './to/toInetAton';
|
|
31
|
+
import { toInetNtoa } from './to/toInetNtoa';
|
|
32
|
+
import { toNum } from './to/toNum';
|
|
33
|
+
import { toPortions } from './to/toPortions';
|
|
34
|
+
import { toTimestamp } from './to/toTimestamp';
|
|
35
|
+
import { toArrFuncArgs } from './to/toArrFuncArgs';
|
|
36
|
+
import { toJSON } from './to/toJSON';
|
|
37
|
+
import { toPhone } from './to/toPhone';
|
|
38
|
+
import { toLower } from './to/toLower';
|
|
39
|
+
import { toPoolName } from './to/toPoolName';
|
|
40
|
+
import { netTCP } from './net/netTCP';
|
|
41
|
+
export { fromJSON, fromTimestamp, isArr, isArrFilled, isBool, isDate, isEmail, isExists, isFunc, isIp, isMac, isNum, isNumFloat, isNumN, isNumP, isNumPZ, isObj, isObjFilled, isPassword, isPhone, isStr, isStrBool, isStrFilled, isStrOrderType, isVar, toBool, toCellDate, toGB, toGH, toInetAton, toInetNtoa, toNum, toPortions, toTimestamp, toArrFuncArgs, toJSON, toPhone, toLower, toPoolName, netTCP, };
|
|
@@ -0,0 +1,84 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.netTCP = exports.toPoolName = exports.toLower = exports.toPhone = exports.toJSON = exports.toArrFuncArgs = exports.toTimestamp = exports.toPortions = exports.toNum = exports.toInetNtoa = exports.toInetAton = exports.toGH = exports.toGB = exports.toCellDate = exports.toBool = exports.isVar = exports.isStrOrderType = exports.isStrFilled = exports.isStrBool = exports.isStr = exports.isPhone = exports.isPassword = exports.isObjFilled = exports.isObj = exports.isNumPZ = exports.isNumP = exports.isNumN = exports.isNumFloat = exports.isNum = exports.isMac = exports.isIp = exports.isFunc = exports.isExists = exports.isEmail = exports.isDate = exports.isBool = exports.isArrFilled = exports.isArr = exports.fromTimestamp = exports.fromJSON = void 0;
|
|
4
|
+
const fromJSON_1 = require("./from/fromJSON");
|
|
5
|
+
Object.defineProperty(exports, "fromJSON", { enumerable: true, get: function () { return fromJSON_1.fromJSON; } });
|
|
6
|
+
const fromTimestamp_1 = require("./from/fromTimestamp");
|
|
7
|
+
Object.defineProperty(exports, "fromTimestamp", { enumerable: true, get: function () { return fromTimestamp_1.fromTimestamp; } });
|
|
8
|
+
const isArr_1 = require("./is/isArr");
|
|
9
|
+
Object.defineProperty(exports, "isArr", { enumerable: true, get: function () { return isArr_1.isArr; } });
|
|
10
|
+
const isArrFilled_1 = require("./is/isArrFilled");
|
|
11
|
+
Object.defineProperty(exports, "isArrFilled", { enumerable: true, get: function () { return isArrFilled_1.isArrFilled; } });
|
|
12
|
+
const isBool_1 = require("./is/isBool");
|
|
13
|
+
Object.defineProperty(exports, "isBool", { enumerable: true, get: function () { return isBool_1.isBool; } });
|
|
14
|
+
const isDate_1 = require("./is/isDate");
|
|
15
|
+
Object.defineProperty(exports, "isDate", { enumerable: true, get: function () { return isDate_1.isDate; } });
|
|
16
|
+
const isEmail_1 = require("./is/isEmail");
|
|
17
|
+
Object.defineProperty(exports, "isEmail", { enumerable: true, get: function () { return isEmail_1.isEmail; } });
|
|
18
|
+
const isExists_1 = require("./is/isExists");
|
|
19
|
+
Object.defineProperty(exports, "isExists", { enumerable: true, get: function () { return isExists_1.isExists; } });
|
|
20
|
+
const isFunc_1 = require("./is/isFunc");
|
|
21
|
+
Object.defineProperty(exports, "isFunc", { enumerable: true, get: function () { return isFunc_1.isFunc; } });
|
|
22
|
+
const isIp_1 = require("./is/isIp");
|
|
23
|
+
Object.defineProperty(exports, "isIp", { enumerable: true, get: function () { return isIp_1.isIp; } });
|
|
24
|
+
const isMac_1 = require("./is/isMac");
|
|
25
|
+
Object.defineProperty(exports, "isMac", { enumerable: true, get: function () { return isMac_1.isMac; } });
|
|
26
|
+
const isNum_1 = require("./is/isNum");
|
|
27
|
+
Object.defineProperty(exports, "isNum", { enumerable: true, get: function () { return isNum_1.isNum; } });
|
|
28
|
+
const isNumFloat_1 = require("./is/isNumFloat");
|
|
29
|
+
Object.defineProperty(exports, "isNumFloat", { enumerable: true, get: function () { return isNumFloat_1.isNumFloat; } });
|
|
30
|
+
const isNumN_1 = require("./is/isNumN");
|
|
31
|
+
Object.defineProperty(exports, "isNumN", { enumerable: true, get: function () { return isNumN_1.isNumN; } });
|
|
32
|
+
const isNumP_1 = require("./is/isNumP");
|
|
33
|
+
Object.defineProperty(exports, "isNumP", { enumerable: true, get: function () { return isNumP_1.isNumP; } });
|
|
34
|
+
const isNumPZ_1 = require("./is/isNumPZ");
|
|
35
|
+
Object.defineProperty(exports, "isNumPZ", { enumerable: true, get: function () { return isNumPZ_1.isNumPZ; } });
|
|
36
|
+
const isObj_1 = require("./is/isObj");
|
|
37
|
+
Object.defineProperty(exports, "isObj", { enumerable: true, get: function () { return isObj_1.isObj; } });
|
|
38
|
+
const isObjFilled_1 = require("./is/isObjFilled");
|
|
39
|
+
Object.defineProperty(exports, "isObjFilled", { enumerable: true, get: function () { return isObjFilled_1.isObjFilled; } });
|
|
40
|
+
const isPassword_1 = require("./is/isPassword");
|
|
41
|
+
Object.defineProperty(exports, "isPassword", { enumerable: true, get: function () { return isPassword_1.isPassword; } });
|
|
42
|
+
const isPhone_1 = require("./is/isPhone");
|
|
43
|
+
Object.defineProperty(exports, "isPhone", { enumerable: true, get: function () { return isPhone_1.isPhone; } });
|
|
44
|
+
const isStr_1 = require("./is/isStr");
|
|
45
|
+
Object.defineProperty(exports, "isStr", { enumerable: true, get: function () { return isStr_1.isStr; } });
|
|
46
|
+
const isStrBool_1 = require("./is/isStrBool");
|
|
47
|
+
Object.defineProperty(exports, "isStrBool", { enumerable: true, get: function () { return isStrBool_1.isStrBool; } });
|
|
48
|
+
const isStrFilled_1 = require("./is/isStrFilled");
|
|
49
|
+
Object.defineProperty(exports, "isStrFilled", { enumerable: true, get: function () { return isStrFilled_1.isStrFilled; } });
|
|
50
|
+
const isStrOrderType_1 = require("./is/isStrOrderType");
|
|
51
|
+
Object.defineProperty(exports, "isStrOrderType", { enumerable: true, get: function () { return isStrOrderType_1.isStrOrderType; } });
|
|
52
|
+
const isVar_1 = require("./is/isVar");
|
|
53
|
+
Object.defineProperty(exports, "isVar", { enumerable: true, get: function () { return isVar_1.isVar; } });
|
|
54
|
+
const toBool_1 = require("./to/toBool");
|
|
55
|
+
Object.defineProperty(exports, "toBool", { enumerable: true, get: function () { return toBool_1.toBool; } });
|
|
56
|
+
const toCellDate_1 = require("./to/toCellDate");
|
|
57
|
+
Object.defineProperty(exports, "toCellDate", { enumerable: true, get: function () { return toCellDate_1.toCellDate; } });
|
|
58
|
+
const toGB_1 = require("./to/toGB");
|
|
59
|
+
Object.defineProperty(exports, "toGB", { enumerable: true, get: function () { return toGB_1.toGB; } });
|
|
60
|
+
const toGH_1 = require("./to/toGH");
|
|
61
|
+
Object.defineProperty(exports, "toGH", { enumerable: true, get: function () { return toGH_1.toGH; } });
|
|
62
|
+
const toInetAton_1 = require("./to/toInetAton");
|
|
63
|
+
Object.defineProperty(exports, "toInetAton", { enumerable: true, get: function () { return toInetAton_1.toInetAton; } });
|
|
64
|
+
const toInetNtoa_1 = require("./to/toInetNtoa");
|
|
65
|
+
Object.defineProperty(exports, "toInetNtoa", { enumerable: true, get: function () { return toInetNtoa_1.toInetNtoa; } });
|
|
66
|
+
const toNum_1 = require("./to/toNum");
|
|
67
|
+
Object.defineProperty(exports, "toNum", { enumerable: true, get: function () { return toNum_1.toNum; } });
|
|
68
|
+
const toPortions_1 = require("./to/toPortions");
|
|
69
|
+
Object.defineProperty(exports, "toPortions", { enumerable: true, get: function () { return toPortions_1.toPortions; } });
|
|
70
|
+
const toTimestamp_1 = require("./to/toTimestamp");
|
|
71
|
+
Object.defineProperty(exports, "toTimestamp", { enumerable: true, get: function () { return toTimestamp_1.toTimestamp; } });
|
|
72
|
+
const toArrFuncArgs_1 = require("./to/toArrFuncArgs");
|
|
73
|
+
Object.defineProperty(exports, "toArrFuncArgs", { enumerable: true, get: function () { return toArrFuncArgs_1.toArrFuncArgs; } });
|
|
74
|
+
const toJSON_1 = require("./to/toJSON");
|
|
75
|
+
Object.defineProperty(exports, "toJSON", { enumerable: true, get: function () { return toJSON_1.toJSON; } });
|
|
76
|
+
const toPhone_1 = require("./to/toPhone");
|
|
77
|
+
Object.defineProperty(exports, "toPhone", { enumerable: true, get: function () { return toPhone_1.toPhone; } });
|
|
78
|
+
const toLower_1 = require("./to/toLower");
|
|
79
|
+
Object.defineProperty(exports, "toLower", { enumerable: true, get: function () { return toLower_1.toLower; } });
|
|
80
|
+
const toPoolName_1 = require("./to/toPoolName");
|
|
81
|
+
Object.defineProperty(exports, "toPoolName", { enumerable: true, get: function () { return toPoolName_1.toPoolName; } });
|
|
82
|
+
const netTCP_1 = require("./net/netTCP");
|
|
83
|
+
Object.defineProperty(exports, "netTCP", { enumerable: true, get: function () { return netTCP_1.netTCP; } });
|
|
84
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":";;;AAAA,8CAA2C;AA0C1C,yFA1CQ,mBAAQ,OA0CR;AAzCT,wDAAqD;AA0CpD,8FA1CQ,6BAAa,OA0CR;AAzCd,sCAAmC;AA0ClC,sFA1CQ,aAAK,OA0CR;AAzCN,kDAA+C;AA0C9C,4FA1CQ,yBAAW,OA0CR;AAzCZ,wCAAqC;AA0CpC,uFA1CQ,eAAM,OA0CR;AAzCP,wCAAqC;AA0CpC,uFA1CQ,eAAM,OA0CR;AAzCP,0CAAuC;AA0CtC,wFA1CQ,iBAAO,OA0CR;AAzCR,4CAAyC;AA0CxC,yFA1CQ,mBAAQ,OA0CR;AAzCT,wCAAqC;AA0CpC,uFA1CQ,eAAM,OA0CR;AAzCP,oCAAiC;AA0ChC,qFA1CQ,WAAI,OA0CR;AAzCL,sCAAmC;AA0ClC,sFA1CQ,aAAK,OA0CR;AAzCN,sCAAmC;AA0ClC,sFA1CQ,aAAK,OA0CR;AAzCN,gDAA6C;AA0C5C,2FA1CQ,uBAAU,OA0CR;AAzCX,wCAAqC;AA0CpC,uFA1CQ,eAAM,OA0CR;AAzCP,wCAAqC;AA0CpC,uFA1CQ,eAAM,OA0CR;AAzCP,0CAAuC;AA0CtC,wFA1CQ,iBAAO,OA0CR;AAzCR,sCAAmC;AA0ClC,sFA1CQ,aAAK,OA0CR;AAzCN,kDAA+C;AA0C9C,4FA1CQ,yBAAW,OA0CR;AAzCZ,gDAA6C;AA0C5C,2FA1CQ,uBAAU,OA0CR;AAzCX,0CAAuC;AA0CtC,wFA1CQ,iBAAO,OA0CR;AAzCR,sCAAmC;AA0ClC,sFA1CQ,aAAK,OA0CR;AAzCN,8CAA2C;AA0C1C,0FA1CQ,qBAAS,OA0CR;AAzCV,kDAA+C;AA0C9C,4FA1CQ,yBAAW,OA0CR;AAzCZ,wDAAqD;AA0CpD,+FA1CQ,+BAAc,OA0CR;AAzCf,sCAAmC;AA0ClC,sFA1CQ,aAAK,OA0CR;AAzCN,wCAAqC;AA0CpC,uFA1CQ,eAAM,OA0CR;AAzCP,gDAA6C;AA0C5C,2FA1CQ,uBAAU,OA0CR;AAzCX,oCAAiC;AA0ChC,qFA1CQ,WAAI,OA0CR;AAzCL,oCAAiC;AA0ChC,qFA1CQ,WAAI,OA0CR;AAzCL,gDAA6C;AA0C5C,2FA1CQ,uBAAU,OA0CR;AAzCX,gDAA6C;AA0C5C,2FA1CQ,uBAAU,OA0CR;AAzCX,sCAAmC;AA0ClC,sFA1CQ,aAAK,OA0CR;AAzCN,gDAA6C;AA0C5C,2FA1CQ,uBAAU,OA0CR;AAzCX,kDAA+C;AA0C9C,4FA1CQ,yBAAW,OA0CR;AAzCZ,sDAAmD;AA0ClD,8FA1CQ,6BAAa,OA0CR;AAzCd,wCAAqC;AA0CpC,uFA1CQ,eAAM,OA0CR;AAzCP,0CAAuC;AA0CtC,wFA1CQ,iBAAO,OA0CR;AAzCR,0CAAuC;AA0CtC,wFA1CQ,iBAAO,OA0CR;AAzCR,gDAA6C;AA0C5C,2FA1CQ,uBAAU,OA0CR;AAzCX,yCAAsC;AA0CrC,uFA1CQ,eAAM,OA0CR"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare function isArr<T = unknown>(value: unknown): value is readonly [T, ...T[]];
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"isArr.js","sourceRoot":"","sources":["../../../src/is/isArr.ts"],"names":[],"mappings":";;AACA,sBAEC;AAFD,SAAgB,KAAK,CAAc,KAAc;IAChD,OAAO,KAAK,CAAC,OAAO,CAAC,KAAK,CAAC,CAAC;AAC7B,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare function isArrFilled<T = unknown>(value: unknown): value is readonly [T, ...T[]];
|
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.isArrFilled = isArrFilled;
|
|
4
|
+
const isArr_1 = require("./isArr");
|
|
4
5
|
function isArrFilled(value) {
|
|
5
|
-
return
|
|
6
|
+
return (0, isArr_1.isArr)(value) && value.length > 0;
|
|
6
7
|
}
|
|
7
8
|
//# sourceMappingURL=isArrFilled.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"isArrFilled.js","sourceRoot":"","sources":["../../../src/is/isArrFilled.ts"],"names":[],"mappings":";;AAEA,kCAEC;AAJD,mCAAgC;AAEhC,SAAgB,WAAW,CAAc,KAAc;IACtD,OAAO,IAAA,aAAK,EAAC,KAAK,CAAC,IAAI,KAAK,CAAC,MAAM,GAAG,CAAC,CAAC;AACzC,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare function isBool(value: unknown): value is boolean;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"isBool.js","sourceRoot":"","sources":["../../../src/is/isBool.ts"],"names":[],"mappings":";;AACA,wBAEC;AAFD,SAAgB,MAAM,CAAC,KAAc;IACpC,OAAO,OAAO,KAAK,KAAK,SAAS,CAAC;AACnC,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare function isDate(value: unknown): boolean;
|
|
@@ -4,9 +4,12 @@ exports.isDate = isDate;
|
|
|
4
4
|
const isStr_1 = require("./isStr");
|
|
5
5
|
const isNum_1 = require("./isNum");
|
|
6
6
|
function isDate(value) {
|
|
7
|
+
if (value instanceof Date) {
|
|
8
|
+
return !Number.isNaN(value.getTime());
|
|
9
|
+
}
|
|
7
10
|
if ((0, isStr_1.isStr)(value) || (0, isNum_1.isNum)(value)) {
|
|
8
|
-
const
|
|
9
|
-
return
|
|
11
|
+
const d = new Date(value);
|
|
12
|
+
return !Number.isNaN(d.getTime());
|
|
10
13
|
}
|
|
11
14
|
return false;
|
|
12
15
|
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"isDate.js","sourceRoot":"","sources":["../../../src/is/isDate.ts"],"names":[],"mappings":";;AAGA,wBAUC;AAbD,mCAAgC;AAChC,mCAAgC;AAEhC,SAAgB,MAAM,CAAC,KAAc;IACpC,IAAI,KAAK,YAAY,IAAI,EAAE,CAAC;QAC3B,OAAO,CAAC,MAAM,CAAC,KAAK,CAAC,KAAK,CAAC,OAAO,EAAE,CAAC,CAAC;IACvC,CAAC;IACD,IAAI,IAAA,aAAK,EAAC,KAAK,CAAC,IAAI,IAAA,aAAK,EAAC,KAAK,CAAC,EAAE,CAAC;QAClC,MAAM,CAAC,GAAG,IAAI,IAAI,CAAC,KAAY,CAAC,CAAC;QAEjC,OAAO,CAAC,MAAM,CAAC,KAAK,CAAC,CAAC,CAAC,OAAO,EAAE,CAAC,CAAC;IACnC,CAAC;IACD,OAAO,KAAK,CAAC;AACd,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare function isEmail(value: unknown): value is string;
|
|
@@ -2,7 +2,8 @@
|
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.isEmail = isEmail;
|
|
4
4
|
const validator_1 = require("validator");
|
|
5
|
+
const isStrFilled_1 = require("./isStrFilled");
|
|
5
6
|
function isEmail(value) {
|
|
6
|
-
return validator_1.default.isEmail(value);
|
|
7
|
+
return (0, isStrFilled_1.isStrFilled)(value) && validator_1.default.isEmail(value);
|
|
7
8
|
}
|
|
8
9
|
//# sourceMappingURL=isEmail.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"isEmail.js","sourceRoot":"","sources":["../../../src/is/isEmail.ts"],"names":[],"mappings":";;AAGA,0BAEC;AALD,yCAAkC;AAClC,+CAA4C;AAE5C,SAAgB,OAAO,CAAC,KAAc;IACrC,OAAO,IAAA,yBAAW,EAAC,KAAK,CAAC,IAAI,mBAAS,CAAC,OAAO,CAAC,KAAK,CAAC,CAAC;AACvD,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare function isExists<T>(value: T | null | undefined): value is T;
|
|
@@ -2,6 +2,6 @@
|
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.isExists = isExists;
|
|
4
4
|
function isExists(value) {
|
|
5
|
-
return
|
|
5
|
+
return value !== null && value !== undefined;
|
|
6
6
|
}
|
|
7
7
|
//# sourceMappingURL=isExists.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"isExists.js","sourceRoot":"","sources":["../../../src/is/isExists.ts"],"names":[],"mappings":";;AACA,4BAEC;AAFD,SAAgB,QAAQ,CAAI,KAA2B;IACtD,OAAO,KAAK,KAAK,IAAI,IAAI,KAAK,KAAK,SAAS,CAAC;AAC9C,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare function isFunc<T extends Function = Function>(value: unknown): value is T;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"isFunc.js","sourceRoot":"","sources":["../../../src/is/isFunc.ts"],"names":[],"mappings":";;AACA,wBAEC;AAFD,SAAgB,MAAM,CAAgC,KAAc;IACnE,OAAO,OAAO,KAAK,KAAK,UAAU,CAAC;AACpC,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare function isIp(value: unknown): value is string;
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.isIp = isIp;
|
|
4
|
+
const isStr_1 = require("./isStr");
|
|
5
|
+
const IPV4_RE = /^(25[0-5]|2[0-4]\d|[01]?\d\d?)\.(25[0-5]|2[0-4]\d|[01]?\d\d?)\.(25[0-5]|2[0-4]\d|[01]?\d\d?)\.(25[0-5]|2[0-4]\d|[01]?\d\d?)$/;
|
|
6
|
+
function isIp(value) {
|
|
7
|
+
if (!(0, isStr_1.isStr)(value)) {
|
|
8
|
+
return false;
|
|
9
|
+
}
|
|
10
|
+
const v = value.trim();
|
|
11
|
+
return IPV4_RE.test(v);
|
|
12
|
+
}
|
|
13
|
+
//# sourceMappingURL=isIp.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"isIp.js","sourceRoot":"","sources":["../../../src/is/isIp.ts"],"names":[],"mappings":";;AAIA,oBAOC;AAXD,mCAAgC;AAEhC,MAAM,OAAO,GAAG,8HAA8H,CAAC;AAE/I,SAAgB,IAAI,CAAC,KAAc;IAClC,IAAI,CAAC,IAAA,aAAK,EAAC,KAAK,CAAC,EAAE,CAAC;QACnB,OAAO,KAAK,CAAC;IACd,CAAC;IACD,MAAM,CAAC,GAAG,KAAK,CAAC,IAAI,EAAE,CAAC;IAEvB,OAAO,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC;AACxB,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare function isMac(value: unknown): value is string;
|