@ricsam/isolate-types 0.1.11 → 0.1.13
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/README.md +12 -11
- package/dist/cjs/index.cjs +2 -1
- package/dist/cjs/index.cjs.map +3 -3
- package/dist/cjs/isolate-types.cjs +795 -2
- package/dist/cjs/isolate-types.cjs.map +3 -3
- package/dist/cjs/package.json +1 -1
- package/dist/cjs/typecheck.cjs.map +1 -1
- package/dist/mjs/index.mjs +3 -1
- package/dist/mjs/index.mjs.map +3 -3
- package/dist/mjs/isolate-types.mjs +795 -2
- package/dist/mjs/isolate-types.mjs.map +3 -3
- package/dist/mjs/package.json +1 -1
- package/dist/mjs/typecheck.mjs.map +1 -1
- package/dist/types/index.d.ts +1 -1
- package/dist/types/isolate-types.d.ts +14 -6
- package/dist/types/typecheck.d.ts +1 -1
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -47,7 +47,7 @@ if (!result.success) {
|
|
|
47
47
|
|
|
48
48
|
| Option | Description |
|
|
49
49
|
|--------|-------------|
|
|
50
|
-
| `include` | Which package types to include: `"core"`, `"fetch"`, `"fs"`, `"console"`, `"encoding"`, `"timers"`, `"testEnvironment"` (default: `["core", "fetch", "fs"]`) |
|
|
50
|
+
| `include` | Which package types to include: `"core"`, `"fetch"`, `"fs"`, `"console"`, `"encoding"`, `"timers"`, `"testEnvironment"`, `"playwright"` (default: `["core", "fetch", "fs"]`) |
|
|
51
51
|
| `compilerOptions` | Additional TypeScript compiler options |
|
|
52
52
|
| `libraryTypes` | External library type definitions for import resolution |
|
|
53
53
|
|
|
@@ -73,16 +73,17 @@ The type definitions are exported as strings for custom use cases:
|
|
|
73
73
|
|
|
74
74
|
```typescript
|
|
75
75
|
import {
|
|
76
|
-
CORE_TYPES,
|
|
77
|
-
CONSOLE_TYPES,
|
|
78
|
-
CRYPTO_TYPES,
|
|
79
|
-
ENCODING_TYPES,
|
|
80
|
-
FETCH_TYPES,
|
|
81
|
-
FS_TYPES,
|
|
82
|
-
PATH_TYPES,
|
|
83
|
-
TEST_ENV_TYPES,
|
|
84
|
-
TIMERS_TYPES,
|
|
85
|
-
|
|
76
|
+
CORE_TYPES, // ReadableStream, Blob, File, URL, etc.
|
|
77
|
+
CONSOLE_TYPES, // console.log, console.time, etc.
|
|
78
|
+
CRYPTO_TYPES, // crypto.subtle, CryptoKey, etc.
|
|
79
|
+
ENCODING_TYPES, // atob, btoa
|
|
80
|
+
FETCH_TYPES, // fetch, Request, Response, serve, etc.
|
|
81
|
+
FS_TYPES, // getDirectory, FileSystemHandle, etc.
|
|
82
|
+
PATH_TYPES, // path.join, path.resolve, etc.
|
|
83
|
+
TEST_ENV_TYPES, // describe, it, expect, etc.
|
|
84
|
+
TIMERS_TYPES, // setTimeout, setInterval, etc.
|
|
85
|
+
PLAYWRIGHT_TYPES, // page, context, browser, Locator, etc.
|
|
86
|
+
TYPE_DEFINITIONS // All types as { core, fetch, fs, playwright, ... }
|
|
86
87
|
} from "@ricsam/isolate-types";
|
|
87
88
|
|
|
88
89
|
// Use with your own ts-morph project
|
package/dist/cjs/index.cjs
CHANGED
|
@@ -34,6 +34,7 @@ __export(exports_src, {
|
|
|
34
34
|
TYPE_DEFINITIONS: () => import_isolate_types.TYPE_DEFINITIONS,
|
|
35
35
|
TIMERS_TYPES: () => import_isolate_types.TIMERS_TYPES,
|
|
36
36
|
TEST_ENV_TYPES: () => import_isolate_types.TEST_ENV_TYPES,
|
|
37
|
+
PLAYWRIGHT_TYPES: () => import_isolate_types.PLAYWRIGHT_TYPES,
|
|
37
38
|
PATH_TYPES: () => import_isolate_types.PATH_TYPES,
|
|
38
39
|
FS_TYPES: () => import_isolate_types.FS_TYPES,
|
|
39
40
|
FETCH_TYPES: () => import_isolate_types.FETCH_TYPES,
|
|
@@ -46,4 +47,4 @@ module.exports = __toCommonJS(exports_src);
|
|
|
46
47
|
var import_isolate_types = require("./isolate-types.cjs");
|
|
47
48
|
var import_typecheck = require("./typecheck.cjs");
|
|
48
49
|
|
|
49
|
-
//# debugId=
|
|
50
|
+
//# debugId=6774E826610E30D464756E2164756E21
|
package/dist/cjs/index.cjs.map
CHANGED
|
@@ -2,9 +2,9 @@
|
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../src/index.ts"],
|
|
4
4
|
"sourcesContent": [
|
|
5
|
-
"/**\n * @ricsam/isolate-types\n *\n * Type definitions and type-checking utilities for isolated-vm V8 sandbox code.\n */\n\n// Re-export type definitions\nexport {\n CORE_TYPES,\n CONSOLE_TYPES,\n CRYPTO_TYPES,\n ENCODING_TYPES,\n FETCH_TYPES,\n FS_TYPES,\n PATH_TYPES,\n TEST_ENV_TYPES,\n TIMERS_TYPES,\n TYPE_DEFINITIONS,\n type TypeDefinitionKey,\n} from \"./isolate-types.cjs\";\n\n// Re-export typecheck utilities\nexport {\n typecheckIsolateCode,\n formatTypecheckErrors,\n type TypecheckResult,\n type TypecheckError,\n type TypecheckOptions,\n type LibraryTypes,\n type LibraryTypeFile,\n} from \"./typecheck.cjs\";\n"
|
|
5
|
+
"/**\n * @ricsam/isolate-types\n *\n * Type definitions and type-checking utilities for isolated-vm V8 sandbox code.\n */\n\n// Re-export type definitions\nexport {\n CORE_TYPES,\n CONSOLE_TYPES,\n CRYPTO_TYPES,\n ENCODING_TYPES,\n FETCH_TYPES,\n FS_TYPES,\n PATH_TYPES,\n TEST_ENV_TYPES,\n TIMERS_TYPES,\n PLAYWRIGHT_TYPES,\n TYPE_DEFINITIONS,\n type TypeDefinitionKey,\n} from \"./isolate-types.cjs\";\n\n// Re-export typecheck utilities\nexport {\n typecheckIsolateCode,\n formatTypecheckErrors,\n type TypecheckResult,\n type TypecheckError,\n type TypecheckOptions,\n type LibraryTypes,\n type LibraryTypeFile,\n} from \"./typecheck.cjs\";\n"
|
|
6
6
|
],
|
|
7
|
-
"mappings": "
|
|
8
|
-
"debugId": "
|
|
7
|
+
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAoBO,IAbP;AAwBO,IARP;",
|
|
8
|
+
"debugId": "6774E826610E30D464756E2164756E21",
|
|
9
9
|
"names": []
|
|
10
10
|
}
|