@dynamic-labs/utils 0.19.0-alpha.9 → 1.0.0-alpha.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/CHANGELOG.md +299 -0
- package/package.json +7 -5
- package/src/CancellablePromise/CancellablePromise.cjs +126 -126
- package/src/CancellablePromise/CancellablePromise.d.ts +54 -54
- package/src/CancellablePromise/CancellablePromise.js +126 -126
- package/src/CancellablePromise/index.d.ts +1 -1
- package/src/bigIntToHex/bigIntToHex.cjs +15 -0
- package/src/bigIntToHex/bigIntToHex.d.ts +1 -0
- package/src/bigIntToHex/bigIntToHex.js +11 -0
- package/src/bigIntToHex/index.d.ts +1 -0
- package/src/bufferToBase64.cjs +5 -5
- package/src/bufferToBase64.d.ts +1 -1
- package/src/bufferToBase64.js +5 -5
- package/src/errors/AccountExistsError.cjs +6 -6
- package/src/errors/AccountExistsError.d.ts +13 -13
- package/src/errors/AccountExistsError.js +6 -6
- package/src/errors/ChainalysisError.cjs +5 -5
- package/src/errors/ChainalysisError.d.ts +5 -5
- package/src/errors/ChainalysisError.js +5 -5
- package/src/errors/CustomError.cjs +16 -16
- package/src/errors/CustomError.d.ts +11 -11
- package/src/errors/CustomError.js +16 -16
- package/src/errors/DynamicError.cjs +1 -1
- package/src/errors/DynamicError.d.ts +3 -3
- package/src/errors/DynamicError.js +1 -1
- package/src/errors/EmailAlreadyExistsError.cjs +4 -4
- package/src/errors/EmailAlreadyExistsError.d.ts +4 -4
- package/src/errors/EmailAlreadyExistsError.js +4 -4
- package/src/errors/EmailProviderError.cjs +4 -4
- package/src/errors/EmailProviderError.d.ts +4 -4
- package/src/errors/EmailProviderError.js +4 -4
- package/src/errors/EmailVerificationError.cjs +4 -4
- package/src/errors/EmailVerificationError.d.ts +4 -4
- package/src/errors/EmailVerificationError.js +4 -4
- package/src/errors/GateBlockedError.cjs +5 -5
- package/src/errors/GateBlockedError.d.ts +5 -5
- package/src/errors/GateBlockedError.js +5 -5
- package/src/errors/MissingEnvironmentIdError.cjs +4 -4
- package/src/errors/MissingEnvironmentIdError.d.ts +4 -4
- package/src/errors/MissingEnvironmentIdError.js +4 -4
- package/src/errors/NoAccessError.cjs +6 -6
- package/src/errors/NoAccessError.d.ts +9 -9
- package/src/errors/NoAccessError.js +6 -6
- package/src/errors/NotSupportedError.cjs +1 -1
- package/src/errors/NotSupportedError.d.ts +3 -3
- package/src/errors/NotSupportedError.js +1 -1
- package/src/errors/SocialAccountAlreadyExistsError.cjs +4 -4
- package/src/errors/SocialAccountAlreadyExistsError.d.ts +4 -4
- package/src/errors/SocialAccountAlreadyExistsError.js +4 -4
- package/src/errors/UserHasAccountWithEmailError.cjs +5 -5
- package/src/errors/UserHasAccountWithEmailError.d.ts +5 -5
- package/src/errors/UserHasAccountWithEmailError.js +5 -5
- package/src/errors/UsernameAlreadyExistsError.cjs +4 -4
- package/src/errors/UsernameAlreadyExistsError.d.ts +4 -4
- package/src/errors/UsernameAlreadyExistsError.js +4 -4
- package/src/errors/WalletNotDeployedError.cjs +4 -4
- package/src/errors/WalletNotDeployedError.d.ts +4 -4
- package/src/errors/WalletNotDeployedError.js +4 -4
- package/src/errors/WalletUsedError.cjs +4 -4
- package/src/errors/WalletUsedError.d.ts +4 -4
- package/src/errors/WalletUsedError.js +4 -4
- package/src/errors/index.d.ts +16 -16
- package/src/getOrMapViemChain.cjs +77 -0
- package/src/getOrMapViemChain.d.ts +11 -0
- package/src/getOrMapViemChain.js +51 -0
- package/src/{getPathFromObject.cjs → getProvidersFromWindow.cjs} +32 -28
- package/src/getProvidersFromWindow.d.ts +7 -0
- package/src/{getPathFromObject.js → getProvidersFromWindow.js} +32 -28
- package/src/index.cjs +17 -2
- package/src/index.d.ts +15 -10
- package/src/index.js +7 -2
- package/src/isBigInt/index.d.ts +1 -0
- package/src/isBigInt/isBigInt.cjs +7 -0
- package/src/isBigInt/isBigInt.d.ts +1 -0
- package/src/isBigInt/isBigInt.js +3 -0
- package/src/isFunction/index.d.ts +1 -1
- package/src/isFunction/isFunction.cjs +1 -1
- package/src/isFunction/isFunction.d.ts +1 -1
- package/src/isFunction/isFunction.js +1 -1
- package/src/isMobile.cjs +121 -110
- package/src/isMobile.d.ts +18 -16
- package/src/isMobile.js +120 -111
- package/src/last.cjs +14 -14
- package/src/last.d.ts +15 -15
- package/src/last.js +14 -14
- package/src/localStorageAsync.cjs +17 -17
- package/src/localStorageAsync.d.ts +3 -3
- package/src/localStorageAsync.js +17 -17
- package/src/logger/index.d.ts +1 -1
- package/src/logger/logger.d.ts +2 -2
- package/src/parseChainId.d.ts +1 -1
- package/src/parseEvmNetworks.cjs +6 -6
- package/src/parseEvmNetworks.d.ts +2 -2
- package/src/parseEvmNetworks.js +6 -6
- package/src/retryableFn.cjs +53 -0
- package/src/retryableFn.d.ts +14 -0
- package/src/retryableFn.js +48 -0
- package/src/sleep/index.d.ts +1 -0
- package/src/sleep/sleep.cjs +12 -0
- package/src/sleep/sleep.d.ts +11 -0
- package/src/sleep/sleep.js +8 -0
- package/src/getPathFromObject.d.ts +0 -8
|
@@ -0,0 +1,77 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
|
+
|
|
5
|
+
var chains = require('viem/chains');
|
|
6
|
+
|
|
7
|
+
function _interopNamespace(e) {
|
|
8
|
+
if (e && e.__esModule) return e;
|
|
9
|
+
var n = Object.create(null);
|
|
10
|
+
if (e) {
|
|
11
|
+
Object.keys(e).forEach(function (k) {
|
|
12
|
+
if (k !== 'default') {
|
|
13
|
+
var d = Object.getOwnPropertyDescriptor(e, k);
|
|
14
|
+
Object.defineProperty(n, k, d.get ? d : {
|
|
15
|
+
enumerable: true,
|
|
16
|
+
get: function () { return e[k]; }
|
|
17
|
+
});
|
|
18
|
+
}
|
|
19
|
+
});
|
|
20
|
+
}
|
|
21
|
+
n["default"] = e;
|
|
22
|
+
return Object.freeze(n);
|
|
23
|
+
}
|
|
24
|
+
|
|
25
|
+
var chains__namespace = /*#__PURE__*/_interopNamespace(chains);
|
|
26
|
+
|
|
27
|
+
// eslint-disable-next-line import/no-namespace
|
|
28
|
+
/**
|
|
29
|
+
* Gets the chain object for the given chain id.
|
|
30
|
+
* @param chainId - Chain id of the target EVM chain.
|
|
31
|
+
* @returns Viem's chain object.
|
|
32
|
+
*/
|
|
33
|
+
const getChain = (chainId) => {
|
|
34
|
+
for (const chain of Object.values(chains__namespace)) {
|
|
35
|
+
if ('id' in chain) {
|
|
36
|
+
if (chain.id === chainId) {
|
|
37
|
+
return chain;
|
|
38
|
+
}
|
|
39
|
+
}
|
|
40
|
+
}
|
|
41
|
+
throw new Error(`Chain with id ${chainId} not found`);
|
|
42
|
+
};
|
|
43
|
+
const mapChain = (network) => {
|
|
44
|
+
var _a;
|
|
45
|
+
return ({
|
|
46
|
+
blockExplorers: ((_a = network.blockExplorerUrls) === null || _a === void 0 ? void 0 : _a[0])
|
|
47
|
+
? {
|
|
48
|
+
default: {
|
|
49
|
+
name: network.blockExplorerUrls[0],
|
|
50
|
+
url: network.blockExplorerUrls[0],
|
|
51
|
+
},
|
|
52
|
+
}
|
|
53
|
+
: undefined,
|
|
54
|
+
id: network.chainId,
|
|
55
|
+
name: network.vanityName || network.chainName,
|
|
56
|
+
nativeCurrency: network.nativeCurrency,
|
|
57
|
+
network: network.chainName,
|
|
58
|
+
rpcUrls: {
|
|
59
|
+
default: { http: network.rpcUrls },
|
|
60
|
+
public: { http: network.rpcUrls },
|
|
61
|
+
},
|
|
62
|
+
});
|
|
63
|
+
};
|
|
64
|
+
const getOrMapViemChain = (network) => {
|
|
65
|
+
let chain;
|
|
66
|
+
try {
|
|
67
|
+
chain = getChain(network.chainId);
|
|
68
|
+
}
|
|
69
|
+
catch (_a) {
|
|
70
|
+
chain = mapChain(network);
|
|
71
|
+
}
|
|
72
|
+
return chain;
|
|
73
|
+
};
|
|
74
|
+
|
|
75
|
+
exports.getChain = getChain;
|
|
76
|
+
exports.getOrMapViemChain = getOrMapViemChain;
|
|
77
|
+
exports.mapChain = mapChain;
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { Chain } from 'viem';
|
|
2
|
+
import * as chains from 'viem/chains';
|
|
3
|
+
import { EvmNetwork } from '@dynamic-labs/types';
|
|
4
|
+
/**
|
|
5
|
+
* Gets the chain object for the given chain id.
|
|
6
|
+
* @param chainId - Chain id of the target EVM chain.
|
|
7
|
+
* @returns Viem's chain object.
|
|
8
|
+
*/
|
|
9
|
+
export declare const getChain: (chainId: number) => chains.Chain;
|
|
10
|
+
export declare const mapChain: (network: EvmNetwork) => Chain;
|
|
11
|
+
export declare const getOrMapViemChain: (network: EvmNetwork) => Chain;
|
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
import * as chains from 'viem/chains';
|
|
2
|
+
|
|
3
|
+
// eslint-disable-next-line import/no-namespace
|
|
4
|
+
/**
|
|
5
|
+
* Gets the chain object for the given chain id.
|
|
6
|
+
* @param chainId - Chain id of the target EVM chain.
|
|
7
|
+
* @returns Viem's chain object.
|
|
8
|
+
*/
|
|
9
|
+
const getChain = (chainId) => {
|
|
10
|
+
for (const chain of Object.values(chains)) {
|
|
11
|
+
if ('id' in chain) {
|
|
12
|
+
if (chain.id === chainId) {
|
|
13
|
+
return chain;
|
|
14
|
+
}
|
|
15
|
+
}
|
|
16
|
+
}
|
|
17
|
+
throw new Error(`Chain with id ${chainId} not found`);
|
|
18
|
+
};
|
|
19
|
+
const mapChain = (network) => {
|
|
20
|
+
var _a;
|
|
21
|
+
return ({
|
|
22
|
+
blockExplorers: ((_a = network.blockExplorerUrls) === null || _a === void 0 ? void 0 : _a[0])
|
|
23
|
+
? {
|
|
24
|
+
default: {
|
|
25
|
+
name: network.blockExplorerUrls[0],
|
|
26
|
+
url: network.blockExplorerUrls[0],
|
|
27
|
+
},
|
|
28
|
+
}
|
|
29
|
+
: undefined,
|
|
30
|
+
id: network.chainId,
|
|
31
|
+
name: network.vanityName || network.chainName,
|
|
32
|
+
nativeCurrency: network.nativeCurrency,
|
|
33
|
+
network: network.chainName,
|
|
34
|
+
rpcUrls: {
|
|
35
|
+
default: { http: network.rpcUrls },
|
|
36
|
+
public: { http: network.rpcUrls },
|
|
37
|
+
},
|
|
38
|
+
});
|
|
39
|
+
};
|
|
40
|
+
const getOrMapViemChain = (network) => {
|
|
41
|
+
let chain;
|
|
42
|
+
try {
|
|
43
|
+
chain = getChain(network.chainId);
|
|
44
|
+
}
|
|
45
|
+
catch (_a) {
|
|
46
|
+
chain = mapChain(network);
|
|
47
|
+
}
|
|
48
|
+
return chain;
|
|
49
|
+
};
|
|
50
|
+
|
|
51
|
+
export { getChain, getOrMapViemChain, mapChain };
|
|
@@ -2,33 +2,37 @@
|
|
|
2
2
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
|
-
/**
|
|
6
|
-
* return the destination (value)
|
|
7
|
-
*
|
|
8
|
-
* @param {
|
|
9
|
-
* @
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
const
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
const
|
|
16
|
-
|
|
17
|
-
result
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
5
|
+
/**
|
|
6
|
+
* return the destination (value)
|
|
7
|
+
*
|
|
8
|
+
* @param {string} path - path in the obj to the item
|
|
9
|
+
* @returns {T[]} - array of found items
|
|
10
|
+
*/
|
|
11
|
+
const getProvidersFromWindow = (path) => {
|
|
12
|
+
const splitPath = path.split('.');
|
|
13
|
+
let result = window;
|
|
14
|
+
const foundProviders = [];
|
|
15
|
+
for (const [index, p] of Object.entries(splitPath)) {
|
|
16
|
+
result = result[p];
|
|
17
|
+
if (typeof result !== 'object' || result === null) {
|
|
18
|
+
return [];
|
|
19
|
+
}
|
|
20
|
+
// we need to check if we have hit the end of the requested path
|
|
21
|
+
if (Number(index) === splitPath.length - 1) {
|
|
22
|
+
if (Array.isArray(result)) {
|
|
23
|
+
result.forEach((p) => foundProviders.push(p));
|
|
24
|
+
}
|
|
25
|
+
else {
|
|
26
|
+
if (result.providers) {
|
|
27
|
+
result.providers.forEach((p) => foundProviders.push(p));
|
|
28
|
+
}
|
|
29
|
+
else {
|
|
30
|
+
foundProviders.push(result);
|
|
31
|
+
}
|
|
32
|
+
}
|
|
33
|
+
}
|
|
34
|
+
}
|
|
35
|
+
return foundProviders;
|
|
32
36
|
};
|
|
33
37
|
|
|
34
|
-
exports.
|
|
38
|
+
exports.getProvidersFromWindow = getProvidersFromWindow;
|
|
@@ -1,30 +1,34 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* return the destination (value)
|
|
3
|
-
*
|
|
4
|
-
* @param {
|
|
5
|
-
* @
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
const
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
const
|
|
12
|
-
|
|
13
|
-
result
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
1
|
+
/**
|
|
2
|
+
* return the destination (value)
|
|
3
|
+
*
|
|
4
|
+
* @param {string} path - path in the obj to the item
|
|
5
|
+
* @returns {T[]} - array of found items
|
|
6
|
+
*/
|
|
7
|
+
const getProvidersFromWindow = (path) => {
|
|
8
|
+
const splitPath = path.split('.');
|
|
9
|
+
let result = window;
|
|
10
|
+
const foundProviders = [];
|
|
11
|
+
for (const [index, p] of Object.entries(splitPath)) {
|
|
12
|
+
result = result[p];
|
|
13
|
+
if (typeof result !== 'object' || result === null) {
|
|
14
|
+
return [];
|
|
15
|
+
}
|
|
16
|
+
// we need to check if we have hit the end of the requested path
|
|
17
|
+
if (Number(index) === splitPath.length - 1) {
|
|
18
|
+
if (Array.isArray(result)) {
|
|
19
|
+
result.forEach((p) => foundProviders.push(p));
|
|
20
|
+
}
|
|
21
|
+
else {
|
|
22
|
+
if (result.providers) {
|
|
23
|
+
result.providers.forEach((p) => foundProviders.push(p));
|
|
24
|
+
}
|
|
25
|
+
else {
|
|
26
|
+
foundProviders.push(result);
|
|
27
|
+
}
|
|
28
|
+
}
|
|
29
|
+
}
|
|
30
|
+
}
|
|
31
|
+
return foundProviders;
|
|
28
32
|
};
|
|
29
33
|
|
|
30
|
-
export {
|
|
34
|
+
export { getProvidersFromWindow };
|
package/src/index.cjs
CHANGED
|
@@ -26,7 +26,12 @@ var isMobile = require('./isMobile.cjs');
|
|
|
26
26
|
var localStorageAsync = require('./localStorageAsync.cjs');
|
|
27
27
|
var bufferToBase64 = require('./bufferToBase64.cjs');
|
|
28
28
|
var last = require('./last.cjs');
|
|
29
|
-
var
|
|
29
|
+
var getProvidersFromWindow = require('./getProvidersFromWindow.cjs');
|
|
30
|
+
var sleep = require('./sleep/sleep.cjs');
|
|
31
|
+
var getOrMapViemChain = require('./getOrMapViemChain.cjs');
|
|
32
|
+
var bigIntToHex = require('./bigIntToHex/bigIntToHex.cjs');
|
|
33
|
+
var isBigInt = require('./isBigInt/isBigInt.cjs');
|
|
34
|
+
var retryableFn = require('./retryableFn.cjs');
|
|
30
35
|
|
|
31
36
|
|
|
32
37
|
|
|
@@ -50,6 +55,7 @@ exports.UserHasAccountWithEmailError = UserHasAccountWithEmailError.UserHasAccou
|
|
|
50
55
|
exports.SocialAccountAlreadyExistsError = SocialAccountAlreadyExistsError.SocialAccountAlreadyExistsError;
|
|
51
56
|
exports.CancellablePromise = CancellablePromise.CancellablePromise;
|
|
52
57
|
exports.isFunction = isFunction.isFunction;
|
|
58
|
+
exports.getAndroidVersion = isMobile.getAndroidVersion;
|
|
53
59
|
exports.isAndroid = isMobile.isAndroid;
|
|
54
60
|
exports.isIOS = isMobile.isIOS;
|
|
55
61
|
exports.isIPad = isMobile.isIPad;
|
|
@@ -58,9 +64,18 @@ exports.isIPhone8OrEarlier = isMobile.isIPhone8OrEarlier;
|
|
|
58
64
|
exports.isLegacySafari = isMobile.isLegacySafari;
|
|
59
65
|
exports.isMobile = isMobile.isMobile;
|
|
60
66
|
exports.isSamsungBrowser = isMobile.isSamsungBrowser;
|
|
67
|
+
exports.isWindows = isMobile.isWindows;
|
|
61
68
|
exports.getItemAsync = localStorageAsync.getItemAsync;
|
|
62
69
|
exports.removeItemAsync = localStorageAsync.removeItemAsync;
|
|
63
70
|
exports.setItemAsync = localStorageAsync.setItemAsync;
|
|
64
71
|
exports.bufferToBase64 = bufferToBase64.bufferToBase64;
|
|
65
72
|
exports.last = last.last;
|
|
66
|
-
exports.
|
|
73
|
+
exports.getProvidersFromWindow = getProvidersFromWindow.getProvidersFromWindow;
|
|
74
|
+
exports.sleep = sleep.sleep;
|
|
75
|
+
exports.getChain = getOrMapViemChain.getChain;
|
|
76
|
+
exports.getOrMapViemChain = getOrMapViemChain.getOrMapViemChain;
|
|
77
|
+
exports.mapChain = getOrMapViemChain.mapChain;
|
|
78
|
+
exports.bigIntToHex = bigIntToHex.bigIntToHex;
|
|
79
|
+
exports.isBigInt = isBigInt.isBigInt;
|
|
80
|
+
exports.FALLBACK_UNDEFINED = retryableFn.FALLBACK_UNDEFINED;
|
|
81
|
+
exports.retryableFn = retryableFn.retryableFn;
|
package/src/index.d.ts
CHANGED
|
@@ -1,10 +1,15 @@
|
|
|
1
|
-
export * from './parseChainId';
|
|
2
|
-
export * from './parseEvmNetworks';
|
|
3
|
-
export * from './errors';
|
|
4
|
-
export * from './CancellablePromise';
|
|
5
|
-
export * from './isFunction';
|
|
6
|
-
export * from './isMobile';
|
|
7
|
-
export * from './localStorageAsync';
|
|
8
|
-
export * from './bufferToBase64';
|
|
9
|
-
export * from './last';
|
|
10
|
-
export * from './
|
|
1
|
+
export * from './parseChainId';
|
|
2
|
+
export * from './parseEvmNetworks';
|
|
3
|
+
export * from './errors';
|
|
4
|
+
export * from './CancellablePromise';
|
|
5
|
+
export * from './isFunction';
|
|
6
|
+
export * from './isMobile';
|
|
7
|
+
export * from './localStorageAsync';
|
|
8
|
+
export * from './bufferToBase64';
|
|
9
|
+
export * from './last';
|
|
10
|
+
export * from './getProvidersFromWindow';
|
|
11
|
+
export * from './sleep';
|
|
12
|
+
export * from './getOrMapViemChain';
|
|
13
|
+
export * from './bigIntToHex';
|
|
14
|
+
export * from './isBigInt';
|
|
15
|
+
export * from './retryableFn';
|
package/src/index.js
CHANGED
|
@@ -18,8 +18,13 @@ export { UserHasAccountWithEmailError } from './errors/UserHasAccountWithEmailEr
|
|
|
18
18
|
export { SocialAccountAlreadyExistsError } from './errors/SocialAccountAlreadyExistsError.js';
|
|
19
19
|
export { CancellablePromise } from './CancellablePromise/CancellablePromise.js';
|
|
20
20
|
export { isFunction } from './isFunction/isFunction.js';
|
|
21
|
-
export { isAndroid, isIOS, isIPad, isIPhone, isIPhone8OrEarlier, isLegacySafari, isMobile, isSamsungBrowser } from './isMobile.js';
|
|
21
|
+
export { getAndroidVersion, isAndroid, isIOS, isIPad, isIPhone, isIPhone8OrEarlier, isLegacySafari, isMobile, isSamsungBrowser, isWindows } from './isMobile.js';
|
|
22
22
|
export { getItemAsync, removeItemAsync, setItemAsync } from './localStorageAsync.js';
|
|
23
23
|
export { bufferToBase64 } from './bufferToBase64.js';
|
|
24
24
|
export { last } from './last.js';
|
|
25
|
-
export {
|
|
25
|
+
export { getProvidersFromWindow } from './getProvidersFromWindow.js';
|
|
26
|
+
export { sleep } from './sleep/sleep.js';
|
|
27
|
+
export { getChain, getOrMapViemChain, mapChain } from './getOrMapViemChain.js';
|
|
28
|
+
export { bigIntToHex } from './bigIntToHex/bigIntToHex.js';
|
|
29
|
+
export { isBigInt } from './isBigInt/isBigInt.js';
|
|
30
|
+
export { FALLBACK_UNDEFINED, retryableFn } from './retryableFn.js';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { isBigInt } from './isBigInt';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare const isBigInt: (value: bigint | unknown) => value is bigint;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export { isFunction } from './isFunction';
|
|
1
|
+
export { isFunction } from './isFunction';
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
|
-
// eslint-disable-next-line @typescript-eslint/ban-types
|
|
5
|
+
// eslint-disable-next-line @typescript-eslint/ban-types
|
|
6
6
|
const isFunction = (value) => typeof value === 'function';
|
|
7
7
|
|
|
8
8
|
exports.isFunction = isFunction;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export declare const isFunction: (value: Function | unknown) => value is Function;
|
|
1
|
+
export declare const isFunction: (value: Function | unknown) => value is Function;
|