@e-mc/types 0.10.9 → 0.10.10

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 CHANGED
@@ -9,7 +9,7 @@
9
9
 
10
10
  ## Interface
11
11
 
12
- * [View Source](https://www.unpkg.com/@e-mc/types@0.10.9/index.d.ts)
12
+ * [View Source](https://www.unpkg.com/@e-mc/types@0.10.10/index.d.ts)
13
13
 
14
14
  ```typescript
15
15
  import type { LogArguments } from "./lib/logger";
@@ -197,10 +197,10 @@ const IMPORT_MAP: Record<string, string | undefined>;
197
197
 
198
198
  ## References
199
199
 
200
- - https://www.unpkg.com/@e-mc/types@0.10.9/index.d.ts
201
- - https://www.unpkg.com/@e-mc/types@0.10.9/lib/logger.d.ts
202
- - https://www.unpkg.com/@e-mc/types@0.10.9/lib/module.d.ts
203
- - https://www.unpkg.com/@e-mc/types@0.10.9/lib/object.d.ts
200
+ - https://www.unpkg.com/@e-mc/types@0.10.10/index.d.ts
201
+ - https://www.unpkg.com/@e-mc/types@0.10.10/lib/logger.d.ts
202
+ - https://www.unpkg.com/@e-mc/types@0.10.10/lib/module.d.ts
203
+ - https://www.unpkg.com/@e-mc/types@0.10.10/lib/object.d.ts
204
204
 
205
205
  * https://developer.mozilla.org/en-US/docs/Web/API/DOMException
206
206
  * https://www.npmjs.com/package/@types/bytes
package/constant.d.ts CHANGED
@@ -1,5 +1,5 @@
1
1
  export const enum INTERNAL {
2
- VERSION = '0.10.9',
2
+ VERSION = '0.10.10',
3
3
  TEMP_DIR = 'tmp',
4
4
  CJS = '__cjs__'
5
5
  }
package/index.js CHANGED
@@ -1124,7 +1124,7 @@ async function importESM(name, isDefault, fromPath) {
1124
1124
  if (fromPath && path.isAbsolute(name)) {
1125
1125
  name = (0, url_1.pathToFileURL)(name).toString();
1126
1126
  }
1127
- const result = Function(`return import("${name}")`)();
1127
+ const result = import(name);
1128
1128
  if (isDefault) {
1129
1129
  const out = await result;
1130
1130
  if (isObject(out) && 'default' in out) {
package/lib/index.d.ts CHANGED
@@ -296,7 +296,7 @@ declare namespace functions {
296
296
  createServer(port: number, secure?: Null<SecureOptions>, active?: boolean): Null<ws.Server>;
297
297
  shutdown(): void;
298
298
  setTimeout(value: number | string): void;
299
- checkTimeout(client: ws | ws.WebSocket): boolean;
299
+ checkTimeout(client: ws.WebSocket): boolean;
300
300
  readonly prototype: IWatch<T, U, V, W>;
301
301
  new(module?: V): IWatch<T, U, V, W>;
302
302
  new(interval?: number, port?: number, securePort?: number, extensions?: unknown[]): IWatch<T, U, V, W>;
package/lib/watch.d.ts CHANGED
@@ -58,8 +58,8 @@ export interface IFileGroup<T extends ExternalAsset = ExternalAsset> extends IAb
58
58
 
59
59
  export interface FileGroupConstructor<T extends ExternalAsset = ExternalAsset> {
60
60
  CONNECTION_TIMEOUT: number;
61
- CLIENT_SESSION: Map<typeof ws, number>;
62
- checkTimeout(client: ws | ws.WebSocket): boolean;
61
+ CLIENT_SESSION: Map<ws.WebSocket, number>;
62
+ checkTimeout(client: ws.WebSocket): boolean;
63
63
  cloneAsset(asset: T): T;
64
64
  readonly prototype: IFileGroup<T>;
65
65
  new(uri: string, assets: T[], abortable: boolean): IFileGroup<T>;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@e-mc/types",
3
- "version": "0.10.9",
3
+ "version": "0.10.10",
4
4
  "description": "Type definitions for E-mc.",
5
5
  "main": "index.js",
6
6
  "types": "index.d.ts",