@pezkuwi/x-bigint 14.0.10 → 14.0.11

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/cjs/index.d.ts ADDED
@@ -0,0 +1,2 @@
1
+ export { packageInfo } from './packageInfo.js';
2
+ export declare const BigInt: BigIntConstructor;
package/cjs/index.js ADDED
@@ -0,0 +1,20 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.BigInt = exports.packageInfo = void 0;
4
+ const x_global_1 = require("@pezkuwi/x-global");
5
+ var packageInfo_js_1 = require("./packageInfo.js");
6
+ Object.defineProperty(exports, "packageInfo", { enumerable: true, get: function () { return packageInfo_js_1.packageInfo; } });
7
+ /**
8
+ * @internal
9
+ *
10
+ * There are _still_ some older environments (specifically RN < 0.70), that does
11
+ * not have proper BigInt support - a non-working fallback is provided for those.
12
+ *
13
+ * We detect availability of BigInt upon usage, so this is purely to allow functional
14
+ * compilation & bundling. Since we have operators such as *+-/ top-level, a number-ish
15
+ * result is used here.
16
+ */
17
+ function invalidFallback() {
18
+ return Number.NaN;
19
+ }
20
+ exports.BigInt = (0, x_global_1.extractGlobal)('BigInt', invalidFallback);
@@ -0,0 +1,3 @@
1
+ {
2
+ "type": "commonjs"
3
+ }
@@ -0,0 +1,6 @@
1
+ export declare const packageInfo: {
2
+ name: string;
3
+ path: string;
4
+ type: string;
5
+ version: string;
6
+ };
@@ -0,0 +1,4 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.packageInfo = void 0;
4
+ exports.packageInfo = { name: '@pezkuwi/x-bigint', path: typeof __dirname === 'string' ? __dirname : 'auto', type: 'cjs', version: '14.0.10' };
package/cjs/shim.d.ts ADDED
@@ -0,0 +1 @@
1
+ export {};
package/cjs/shim.js ADDED
@@ -0,0 +1,5 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ const x_bigint_1 = require("@pezkuwi/x-bigint");
4
+ const x_global_1 = require("@pezkuwi/x-global");
5
+ (0, x_global_1.exposeGlobal)('BigInt', x_bigint_1.BigInt);
package/index.d.ts ADDED
@@ -0,0 +1,2 @@
1
+ export { packageInfo } from './packageInfo.js';
2
+ export declare const BigInt: BigIntConstructor;
package/index.js ADDED
@@ -0,0 +1,16 @@
1
+ import { extractGlobal } from '@pezkuwi/x-global';
2
+ export { packageInfo } from './packageInfo.js';
3
+ /**
4
+ * @internal
5
+ *
6
+ * There are _still_ some older environments (specifically RN < 0.70), that does
7
+ * not have proper BigInt support - a non-working fallback is provided for those.
8
+ *
9
+ * We detect availability of BigInt upon usage, so this is purely to allow functional
10
+ * compilation & bundling. Since we have operators such as *+-/ top-level, a number-ish
11
+ * result is used here.
12
+ */
13
+ function invalidFallback() {
14
+ return Number.NaN;
15
+ }
16
+ export const BigInt = /*#__PURE__*/ extractGlobal('BigInt', invalidFallback);
package/package.json CHANGED
@@ -15,12 +15,93 @@
15
15
  },
16
16
  "sideEffects": [
17
17
  "./shim.js",
18
- "./shim.cjs"
18
+ "./cjs/shim.js"
19
19
  ],
20
20
  "type": "module",
21
- "version": "14.0.10",
21
+ "version": "14.0.11",
22
+ "main": "./cjs/index.js",
23
+ "module": "./index.js",
24
+ "types": "./index.d.ts",
25
+ "exports": {
26
+ "./cjs/package.json": "./cjs/package.json",
27
+ "./cjs/*": "./cjs/*.js",
28
+ ".": {
29
+ "module": {
30
+ "types": "./index.d.ts",
31
+ "default": "./index.js"
32
+ },
33
+ "require": {
34
+ "types": "./cjs/index.d.ts",
35
+ "default": "./cjs/index.js"
36
+ },
37
+ "default": {
38
+ "types": "./index.d.ts",
39
+ "default": "./index.js"
40
+ }
41
+ },
42
+ "./package.json": {
43
+ "require": "./cjs/package.json",
44
+ "default": "./package.json"
45
+ },
46
+ "./packageInfo.js": {
47
+ "module": {
48
+ "types": "./packageInfo.d.ts",
49
+ "default": "./packageInfo.js"
50
+ },
51
+ "require": {
52
+ "types": "./cjs/packageInfo.d.ts",
53
+ "default": "./cjs/packageInfo.js"
54
+ },
55
+ "default": {
56
+ "types": "./packageInfo.d.ts",
57
+ "default": "./packageInfo.js"
58
+ }
59
+ },
60
+ "./packageInfo": {
61
+ "module": {
62
+ "types": "./packageInfo.d.ts",
63
+ "default": "./packageInfo.js"
64
+ },
65
+ "require": {
66
+ "types": "./cjs/packageInfo.d.ts",
67
+ "default": "./cjs/packageInfo.js"
68
+ },
69
+ "default": {
70
+ "types": "./packageInfo.d.ts",
71
+ "default": "./packageInfo.js"
72
+ }
73
+ },
74
+ "./shim.js": {
75
+ "module": {
76
+ "types": "./shim.d.ts",
77
+ "default": "./shim.js"
78
+ },
79
+ "require": {
80
+ "types": "./cjs/shim.d.ts",
81
+ "default": "./cjs/shim.js"
82
+ },
83
+ "default": {
84
+ "types": "./shim.d.ts",
85
+ "default": "./shim.js"
86
+ }
87
+ },
88
+ "./shim": {
89
+ "module": {
90
+ "types": "./shim.d.ts",
91
+ "default": "./shim.js"
92
+ },
93
+ "require": {
94
+ "types": "./cjs/shim.d.ts",
95
+ "default": "./cjs/shim.js"
96
+ },
97
+ "default": {
98
+ "types": "./shim.d.ts",
99
+ "default": "./shim.js"
100
+ }
101
+ }
102
+ },
22
103
  "dependencies": {
23
- "@pezkuwi/x-global": "14.0.10",
104
+ "@pezkuwi/x-global": "14.0.11",
24
105
  "tslib": "^2.8.0"
25
106
  }
26
- }
107
+ }
@@ -0,0 +1,6 @@
1
+ export declare const packageInfo: {
2
+ name: string;
3
+ path: string;
4
+ type: string;
5
+ version: string;
6
+ };
package/packageInfo.js ADDED
@@ -0,0 +1 @@
1
+ export const packageInfo = { name: '@pezkuwi/x-bigint', path: (import.meta && import.meta.url) ? new URL(import.meta.url).pathname.substring(0, new URL(import.meta.url).pathname.lastIndexOf('/') + 1) : 'auto', type: 'esm', version: '14.0.10' };
package/shim.d.ts ADDED
@@ -0,0 +1 @@
1
+ export {};
package/shim.js ADDED
@@ -0,0 +1,3 @@
1
+ import { BigInt } from '@pezkuwi/x-bigint';
2
+ import { exposeGlobal } from '@pezkuwi/x-global';
3
+ exposeGlobal('BigInt', BigInt);