@gjsify/inspector 0.4.31 → 0.4.33

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.
Files changed (2) hide show
  1. package/globals.mjs +13 -0
  2. package/package.json +14 -5
package/globals.mjs ADDED
@@ -0,0 +1,13 @@
1
+ /**
2
+ * Re-exports native `node:inspector` for use in Node.js builds.
3
+ *
4
+ * On Node, `node:inspector` is built into the runtime — so a Node-target
5
+ * bundle that imports `@gjsify/inspector` is routed here by the
6
+ * resolver's `gjsify.runtimes.node === "native"` rule. This avoids dragging
7
+ * the GJS polyfill into Node bundles entirely.
8
+ *
9
+ * GJS bundles do NOT consult this file; they route to `@gjsify/inspector`'s
10
+ * own `lib/esm/index.js` (the polyfill).
11
+ */
12
+ export * from 'node:inspector';
13
+ export { default } from 'node:inspector';
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@gjsify/inspector",
3
- "version": "0.4.31",
3
+ "version": "0.4.33",
4
4
  "description": "Node.js inspector module for Gjs",
5
5
  "type": "module",
6
6
  "module": "lib/esm/index.js",
@@ -9,10 +9,12 @@
9
9
  ".": {
10
10
  "types": "./lib/types/index.d.ts",
11
11
  "default": "./lib/esm/index.js"
12
- }
12
+ },
13
+ "./globals": "./globals.mjs"
13
14
  },
14
15
  "files": [
15
- "lib"
16
+ "lib",
17
+ "globals.mjs"
16
18
  ],
17
19
  "scripts": {
18
20
  "clear": "rm -rf lib tsconfig.tsbuildinfo tsconfig.types.tsbuildinfo test.gjs.mjs test.node.mjs || exit 0",
@@ -33,9 +35,16 @@
33
35
  "inspector"
34
36
  ],
35
37
  "devDependencies": {
36
- "@gjsify/cli": "^0.4.31",
37
- "@gjsify/unit": "^0.4.31",
38
+ "@gjsify/cli": "^0.4.33",
39
+ "@gjsify/unit": "^0.4.33",
38
40
  "@types/node": "^25.9.1",
39
41
  "typescript": "^6.0.3"
42
+ },
43
+ "gjsify": {
44
+ "runtimes": {
45
+ "gjs": "polyfill",
46
+ "node": "native",
47
+ "browser": "polyfill"
48
+ }
40
49
  }
41
50
  }