@fireproof/core 0.19.112-dev-web → 0.19.112-dev-dyn

Sign up to get free protection for your applications and to get access to all the features.
Files changed (83) hide show
  1. package/{chunk-GZANCVTS.js → chunk-D4E6UX6S.js} +1 -8
  2. package/{chunk-GZANCVTS.js.map → chunk-D4E6UX6S.js.map} +1 -1
  3. package/{web/chunk-S4HRSKEO.js → chunk-PWEDYV5H.js} +26 -30
  4. package/chunk-PWEDYV5H.js.map +1 -0
  5. package/chunk-PZ5AY32C.js +10 -0
  6. package/{gateway@skip-iife-OZ2V32XH.js → gateway-72EUHYEL.js} +5 -4
  7. package/gateway-72EUHYEL.js.map +1 -0
  8. package/gateway-SK2ERWD3.js +70 -0
  9. package/gateway-SK2ERWD3.js.map +1 -0
  10. package/index.cjs +105 -286
  11. package/index.cjs.map +1 -1
  12. package/index.d.cts +2 -3
  13. package/index.d.ts +2 -3
  14. package/index.global.js +233 -188
  15. package/index.global.js.map +1 -1
  16. package/index.js +17 -17
  17. package/index.js.map +1 -1
  18. package/{key-bag-file-4TYN2H7F.js → key-bag-file-VP6Y7N26.js} +4 -3
  19. package/{key-bag-file-4TYN2H7F.js.map → key-bag-file-VP6Y7N26.js.map} +1 -1
  20. package/{key-bag-indexdb-JEOAS4WM.js → key-bag-indexdb-N5GQ5GSH.js} +4 -3
  21. package/{key-bag-indexdb-JEOAS4WM.js.map → key-bag-indexdb-N5GQ5GSH.js.map} +1 -1
  22. package/metafile-cjs.json +1 -1
  23. package/metafile-esm.json +1 -1
  24. package/metafile-iife.json +1 -1
  25. package/node/chunk-4A4RAVNS.js +17 -0
  26. package/node/chunk-4A4RAVNS.js.map +1 -0
  27. package/node/mem-filesystem.cjs +72 -0
  28. package/node/mem-filesystem.cjs.map +1 -0
  29. package/node/mem-filesystem.d.cts +25 -0
  30. package/node/mem-filesystem.d.ts +25 -0
  31. package/{mem-filesystem@skip-iife-CJI7IIKV.js → node/mem-filesystem.js} +3 -4
  32. package/node/mem-filesystem.js.map +1 -0
  33. package/node/metafile-cjs.json +1 -0
  34. package/node/metafile-esm.json +1 -0
  35. package/node/node-filesystem.cjs +86 -0
  36. package/node/node-filesystem.cjs.map +1 -0
  37. package/node/node-filesystem.d.cts +36 -0
  38. package/node/node-filesystem.d.ts +36 -0
  39. package/{node-filesystem@skip-iife-O74VAABQ.js → node/node-filesystem.js} +3 -4
  40. package/node/node-filesystem.js.map +1 -0
  41. package/node/types-DARSfXlb.d.cts +23 -0
  42. package/node/types-DARSfXlb.d.ts +23 -0
  43. package/package.json +1 -1
  44. package/utils-WS4AZWA7.js +13 -0
  45. package/web/gateway-impl.cjs +319 -0
  46. package/web/gateway-impl.cjs.map +1 -0
  47. package/web/gateway-impl.d.cts +86 -0
  48. package/web/gateway-impl.d.ts +86 -0
  49. package/{gateway@skip-esm-O655UEIP.js → web/gateway-impl.js} +165 -20
  50. package/web/gateway-impl.js.map +1 -0
  51. package/web/metafile-cjs.json +1 -1
  52. package/web/metafile-esm.json +1 -1
  53. package/chunk-LNFBDD6E.js +0 -75
  54. package/chunk-LNFBDD6E.js.map +0 -1
  55. package/chunk-PB4BKL4O.js +0 -7
  56. package/chunk-PB4BKL4O.js.map +0 -1
  57. package/gateway@skip-esm-O655UEIP.js.map +0 -1
  58. package/gateway@skip-iife-OZ2V32XH.js.map +0 -1
  59. package/mem-filesystem@skip-iife-CJI7IIKV.js.map +0 -1
  60. package/node-filesystem@skip-iife-O74VAABQ.js.map +0 -1
  61. package/utils-L7MUZUJX.js +0 -14
  62. package/web/bundle-not-impl-UH74NK5L.js +0 -5
  63. package/web/bundle-not-impl-UH74NK5L.js.map +0 -1
  64. package/web/chunk-2DC5ZIR4.js +0 -7
  65. package/web/chunk-2DC5ZIR4.js.map +0 -1
  66. package/web/chunk-Q5W7UNMP.js +0 -292
  67. package/web/chunk-Q5W7UNMP.js.map +0 -1
  68. package/web/chunk-S4HRSKEO.js.map +0 -1
  69. package/web/gateway@skip-esm-GI5PRACF.js +0 -165
  70. package/web/gateway@skip-esm-GI5PRACF.js.map +0 -1
  71. package/web/index.cjs +0 -4138
  72. package/web/index.cjs.map +0 -1
  73. package/web/index.d.cts +0 -1139
  74. package/web/index.d.ts +0 -1139
  75. package/web/index.js +0 -3478
  76. package/web/index.js.map +0 -1
  77. package/web/key-bag-file-4SJQGORQ.js +0 -54
  78. package/web/key-bag-file-4SJQGORQ.js.map +0 -1
  79. package/web/key-bag-indexdb-GSQOUUVQ.js +0 -50
  80. package/web/key-bag-indexdb-GSQOUUVQ.js.map +0 -1
  81. package/web/utils-EFZJNXH5.js +0 -14
  82. /package/{utils-L7MUZUJX.js.map → chunk-PZ5AY32C.js.map} +0 -0
  83. /package/{web/utils-EFZJNXH5.js.map → utils-WS4AZWA7.js.map} +0 -0
@@ -0,0 +1,17 @@
1
+ // src/runtime/gateways/file/node/to-array-buffer.ts
2
+ function toArrayBuffer(buffer) {
3
+ if (typeof buffer === "string") {
4
+ buffer = Buffer.from(buffer);
5
+ }
6
+ const ab = new ArrayBuffer(buffer.length);
7
+ const view = new Uint8Array(ab);
8
+ for (let i = 0; i < buffer.length; ++i) {
9
+ view[i] = buffer[i];
10
+ }
11
+ return view;
12
+ }
13
+
14
+ export {
15
+ toArrayBuffer
16
+ };
17
+ //# sourceMappingURL=chunk-4A4RAVNS.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../../../src/runtime/gateways/file/node/to-array-buffer.ts"],"sourcesContent":["export function toArrayBuffer(buffer: Buffer | string): Uint8Array {\n if (typeof buffer === \"string\") {\n buffer = Buffer.from(buffer);\n }\n const ab = new ArrayBuffer(buffer.length);\n const view = new Uint8Array(ab);\n for (let i = 0; i < buffer.length; ++i) {\n view[i] = buffer[i];\n }\n return view;\n}\n"],"mappings":";AAAO,SAAS,cAAc,QAAqC;AACjE,MAAI,OAAO,WAAW,UAAU;AAC9B,aAAS,OAAO,KAAK,MAAM;AAAA,EAC7B;AACA,QAAM,KAAK,IAAI,YAAY,OAAO,MAAM;AACxC,QAAM,OAAO,IAAI,WAAW,EAAE;AAC9B,WAAS,IAAI,GAAG,IAAI,OAAO,QAAQ,EAAE,GAAG;AACtC,SAAK,CAAC,IAAI,OAAO,CAAC;AAAA,EACpB;AACA,SAAO;AACT;","names":[]}
@@ -0,0 +1,72 @@
1
+ "use strict";
2
+ var __defProp = Object.defineProperty;
3
+ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
4
+ var __getOwnPropNames = Object.getOwnPropertyNames;
5
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
6
+ var __export = (target, all) => {
7
+ for (var name in all)
8
+ __defProp(target, name, { get: all[name], enumerable: true });
9
+ };
10
+ var __copyProps = (to, from, except, desc) => {
11
+ if (from && typeof from === "object" || typeof from === "function") {
12
+ for (let key of __getOwnPropNames(from))
13
+ if (!__hasOwnProp.call(to, key) && key !== except)
14
+ __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
15
+ }
16
+ return to;
17
+ };
18
+ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
19
+
20
+ // src/runtime/gateways/file/node/mem-filesystem.ts
21
+ var mem_filesystem_exports = {};
22
+ __export(mem_filesystem_exports, {
23
+ MemFileSystem: () => MemFileSystem
24
+ });
25
+ module.exports = __toCommonJS(mem_filesystem_exports);
26
+ var import_memfs = require("memfs");
27
+
28
+ // src/runtime/gateways/file/node/to-array-buffer.ts
29
+ function toArrayBuffer(buffer) {
30
+ if (typeof buffer === "string") {
31
+ buffer = Buffer.from(buffer);
32
+ }
33
+ const ab = new ArrayBuffer(buffer.length);
34
+ const view = new Uint8Array(ab);
35
+ for (let i = 0; i < buffer.length; ++i) {
36
+ view[i] = buffer[i];
37
+ }
38
+ return view;
39
+ }
40
+
41
+ // src/runtime/gateways/file/node/mem-filesystem.ts
42
+ var MemFileSystem = class {
43
+ async start() {
44
+ return this;
45
+ }
46
+ mkdir(path, options) {
47
+ return import_memfs.fs.promises.mkdir(path, options);
48
+ }
49
+ readdir(path, options) {
50
+ return import_memfs.fs.promises.readdir(path, options);
51
+ }
52
+ rm(path, options) {
53
+ return import_memfs.fs.promises.rm(path, options);
54
+ }
55
+ copyFile(source, destination) {
56
+ return import_memfs.fs.promises.copyFile(source, destination);
57
+ }
58
+ async readfile(path, options) {
59
+ const ret = await import_memfs.fs.promises.readFile(path, options);
60
+ return toArrayBuffer(ret);
61
+ }
62
+ stat(path) {
63
+ return import_memfs.fs.promises.stat(path);
64
+ }
65
+ unlink(path) {
66
+ return import_memfs.fs.promises.unlink(path);
67
+ }
68
+ writefile(path, data) {
69
+ return import_memfs.fs.promises.writeFile(path, Buffer.from(data));
70
+ }
71
+ };
72
+ //# sourceMappingURL=mem-filesystem.cjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../../../src/runtime/gateways/file/node/mem-filesystem.ts","../../../src/runtime/gateways/file/node/to-array-buffer.ts"],"sourcesContent":["import type { PathLike, MakeDirectoryOptions, Stats } from \"fs\";\nimport { fs } from \"memfs\";\nimport { IReaddirOptions } from \"memfs/lib/node/types/options.js\";\nimport { toArrayBuffer } from \"./to-array-buffer.js\";\nimport type { SysFileSystem } from \"../../../../types.js\";\n\nexport class MemFileSystem implements SysFileSystem {\n async start(): Promise<SysFileSystem> {\n return this;\n }\n mkdir(path: PathLike, options?: { recursive: boolean }): Promise<string | undefined> {\n return fs.promises.mkdir(path, options);\n }\n readdir(path: PathLike, options?: IReaddirOptions): Promise<string[]> {\n return fs.promises.readdir(path, options) as Promise<string[]>;\n }\n rm(path: PathLike, options?: MakeDirectoryOptions & { recursive: boolean }): Promise<void> {\n return fs.promises.rm(path, options);\n }\n copyFile(source: PathLike, destination: PathLike): Promise<void> {\n return fs.promises.copyFile(source, destination);\n }\n async readfile(path: PathLike, options?: { encoding: BufferEncoding; flag?: string }): Promise<Uint8Array> {\n const ret = await fs.promises.readFile(path, options);\n return toArrayBuffer(ret);\n }\n stat(path: PathLike): Promise<Stats> {\n return fs.promises.stat(path) as Promise<Stats>;\n }\n unlink(path: PathLike): Promise<void> {\n return fs.promises.unlink(path);\n }\n writefile(path: PathLike, data: Uint8Array | string): Promise<void> {\n return fs.promises.writeFile(path, Buffer.from(data));\n }\n}\n","export function toArrayBuffer(buffer: Buffer | string): Uint8Array {\n if (typeof buffer === \"string\") {\n buffer = Buffer.from(buffer);\n }\n const ab = new ArrayBuffer(buffer.length);\n const view = new Uint8Array(ab);\n for (let i = 0; i < buffer.length; ++i) {\n view[i] = buffer[i];\n }\n return view;\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AACA,mBAAmB;;;ACDZ,SAAS,cAAc,QAAqC;AACjE,MAAI,OAAO,WAAW,UAAU;AAC9B,aAAS,OAAO,KAAK,MAAM;AAAA,EAC7B;AACA,QAAM,KAAK,IAAI,YAAY,OAAO,MAAM;AACxC,QAAM,OAAO,IAAI,WAAW,EAAE;AAC9B,WAAS,IAAI,GAAG,IAAI,OAAO,QAAQ,EAAE,GAAG;AACtC,SAAK,CAAC,IAAI,OAAO,CAAC;AAAA,EACpB;AACA,SAAO;AACT;;;ADJO,IAAM,gBAAN,MAA6C;AAAA,EAClD,MAAM,QAAgC;AACpC,WAAO;AAAA,EACT;AAAA,EACA,MAAM,MAAgB,SAA+D;AACnF,WAAO,gBAAG,SAAS,MAAM,MAAM,OAAO;AAAA,EACxC;AAAA,EACA,QAAQ,MAAgB,SAA8C;AACpE,WAAO,gBAAG,SAAS,QAAQ,MAAM,OAAO;AAAA,EAC1C;AAAA,EACA,GAAG,MAAgB,SAAwE;AACzF,WAAO,gBAAG,SAAS,GAAG,MAAM,OAAO;AAAA,EACrC;AAAA,EACA,SAAS,QAAkB,aAAsC;AAC/D,WAAO,gBAAG,SAAS,SAAS,QAAQ,WAAW;AAAA,EACjD;AAAA,EACA,MAAM,SAAS,MAAgB,SAA4E;AACzG,UAAM,MAAM,MAAM,gBAAG,SAAS,SAAS,MAAM,OAAO;AACpD,WAAO,cAAc,GAAG;AAAA,EAC1B;AAAA,EACA,KAAK,MAAgC;AACnC,WAAO,gBAAG,SAAS,KAAK,IAAI;AAAA,EAC9B;AAAA,EACA,OAAO,MAA+B;AACpC,WAAO,gBAAG,SAAS,OAAO,IAAI;AAAA,EAChC;AAAA,EACA,UAAU,MAAgB,MAA0C;AAClE,WAAO,gBAAG,SAAS,UAAU,MAAM,OAAO,KAAK,IAAI,CAAC;AAAA,EACtD;AACF;","names":[]}
@@ -0,0 +1,25 @@
1
+ import { PathLike, MakeDirectoryOptions, Stats } from 'fs';
2
+ import { IReaddirOptions } from 'memfs/lib/node/types/options.js';
3
+ import { S as SysFileSystem } from './types-DARSfXlb.cjs';
4
+
5
+ declare class MemFileSystem implements SysFileSystem {
6
+ start(): Promise<SysFileSystem>;
7
+ mkdir(path: PathLike, options?: {
8
+ recursive: boolean;
9
+ }): Promise<string | undefined>;
10
+ readdir(path: PathLike, options?: IReaddirOptions): Promise<string[]>;
11
+ rm(path: PathLike, options?: MakeDirectoryOptions & {
12
+ recursive: boolean;
13
+ }): Promise<void>;
14
+ copyFile(source: PathLike, destination: PathLike): Promise<void>;
15
+ readfile(path: PathLike, options?: {
16
+ encoding: BufferEncoding;
17
+ flag?: string;
18
+ }): Promise<Uint8Array>;
19
+ stat(path: PathLike): Promise<Stats>;
20
+ unlink(path: PathLike): Promise<void>;
21
+ writefile(path: PathLike, data: Uint8Array | string): Promise<void>;
22
+ }
23
+
24
+ export { MemFileSystem };
25
+ declare module '@fireproof/core/node'
@@ -0,0 +1,25 @@
1
+ import { PathLike, MakeDirectoryOptions, Stats } from 'fs';
2
+ import { IReaddirOptions } from 'memfs/lib/node/types/options.js';
3
+ import { S as SysFileSystem } from './types-DARSfXlb.js';
4
+
5
+ declare class MemFileSystem implements SysFileSystem {
6
+ start(): Promise<SysFileSystem>;
7
+ mkdir(path: PathLike, options?: {
8
+ recursive: boolean;
9
+ }): Promise<string | undefined>;
10
+ readdir(path: PathLike, options?: IReaddirOptions): Promise<string[]>;
11
+ rm(path: PathLike, options?: MakeDirectoryOptions & {
12
+ recursive: boolean;
13
+ }): Promise<void>;
14
+ copyFile(source: PathLike, destination: PathLike): Promise<void>;
15
+ readfile(path: PathLike, options?: {
16
+ encoding: BufferEncoding;
17
+ flag?: string;
18
+ }): Promise<Uint8Array>;
19
+ stat(path: PathLike): Promise<Stats>;
20
+ unlink(path: PathLike): Promise<void>;
21
+ writefile(path: PathLike, data: Uint8Array | string): Promise<void>;
22
+ }
23
+
24
+ export { MemFileSystem };
25
+ declare module '@fireproof/core/node'
@@ -1,9 +1,8 @@
1
1
  import {
2
2
  toArrayBuffer
3
- } from "./chunk-LNFBDD6E.js";
4
- import "./chunk-GZANCVTS.js";
3
+ } from "./chunk-4A4RAVNS.js";
5
4
 
6
- // src/runtime/gateways/file/mem-filesystem@skip-iife.ts
5
+ // src/runtime/gateways/file/node/mem-filesystem.ts
7
6
  import { fs } from "memfs";
8
7
  var MemFileSystem = class {
9
8
  async start() {
@@ -38,4 +37,4 @@ var MemFileSystem = class {
38
37
  export {
39
38
  MemFileSystem
40
39
  };
41
- //# sourceMappingURL=mem-filesystem@skip-iife-CJI7IIKV.js.map
40
+ //# sourceMappingURL=mem-filesystem.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../../../src/runtime/gateways/file/node/mem-filesystem.ts"],"sourcesContent":["import type { PathLike, MakeDirectoryOptions, Stats } from \"fs\";\nimport { fs } from \"memfs\";\nimport { IReaddirOptions } from \"memfs/lib/node/types/options.js\";\nimport { toArrayBuffer } from \"./to-array-buffer.js\";\nimport type { SysFileSystem } from \"../../../../types.js\";\n\nexport class MemFileSystem implements SysFileSystem {\n async start(): Promise<SysFileSystem> {\n return this;\n }\n mkdir(path: PathLike, options?: { recursive: boolean }): Promise<string | undefined> {\n return fs.promises.mkdir(path, options);\n }\n readdir(path: PathLike, options?: IReaddirOptions): Promise<string[]> {\n return fs.promises.readdir(path, options) as Promise<string[]>;\n }\n rm(path: PathLike, options?: MakeDirectoryOptions & { recursive: boolean }): Promise<void> {\n return fs.promises.rm(path, options);\n }\n copyFile(source: PathLike, destination: PathLike): Promise<void> {\n return fs.promises.copyFile(source, destination);\n }\n async readfile(path: PathLike, options?: { encoding: BufferEncoding; flag?: string }): Promise<Uint8Array> {\n const ret = await fs.promises.readFile(path, options);\n return toArrayBuffer(ret);\n }\n stat(path: PathLike): Promise<Stats> {\n return fs.promises.stat(path) as Promise<Stats>;\n }\n unlink(path: PathLike): Promise<void> {\n return fs.promises.unlink(path);\n }\n writefile(path: PathLike, data: Uint8Array | string): Promise<void> {\n return fs.promises.writeFile(path, Buffer.from(data));\n }\n}\n"],"mappings":";;;;;AACA,SAAS,UAAU;AAKZ,IAAM,gBAAN,MAA6C;AAAA,EAClD,MAAM,QAAgC;AACpC,WAAO;AAAA,EACT;AAAA,EACA,MAAM,MAAgB,SAA+D;AACnF,WAAO,GAAG,SAAS,MAAM,MAAM,OAAO;AAAA,EACxC;AAAA,EACA,QAAQ,MAAgB,SAA8C;AACpE,WAAO,GAAG,SAAS,QAAQ,MAAM,OAAO;AAAA,EAC1C;AAAA,EACA,GAAG,MAAgB,SAAwE;AACzF,WAAO,GAAG,SAAS,GAAG,MAAM,OAAO;AAAA,EACrC;AAAA,EACA,SAAS,QAAkB,aAAsC;AAC/D,WAAO,GAAG,SAAS,SAAS,QAAQ,WAAW;AAAA,EACjD;AAAA,EACA,MAAM,SAAS,MAAgB,SAA4E;AACzG,UAAM,MAAM,MAAM,GAAG,SAAS,SAAS,MAAM,OAAO;AACpD,WAAO,cAAc,GAAG;AAAA,EAC1B;AAAA,EACA,KAAK,MAAgC;AACnC,WAAO,GAAG,SAAS,KAAK,IAAI;AAAA,EAC9B;AAAA,EACA,OAAO,MAA+B;AACpC,WAAO,GAAG,SAAS,OAAO,IAAI;AAAA,EAChC;AAAA,EACA,UAAU,MAAgB,MAA0C;AAClE,WAAO,GAAG,SAAS,UAAU,MAAM,OAAO,KAAK,IAAI,CAAC;AAAA,EACtD;AACF;","names":[]}
@@ -0,0 +1 @@
1
+ {"inputs":{"src/runtime/gateways/file/node/to-array-buffer.ts":{"bytes":313,"imports":[],"format":"esm"},"src/runtime/gateways/file/node/mem-filesystem.ts":{"bytes":1466,"imports":[{"path":"memfs","kind":"import-statement","external":true},{"path":"memfs/lib/node/types/options.js","kind":"import-statement","external":true},{"path":"src/runtime/gateways/file/node/to-array-buffer.ts","kind":"import-statement","original":"./to-array-buffer.js"}],"format":"esm"},"src/runtime/gateways/file/node/node-filesystem.ts":{"bytes":3143,"imports":[{"path":"src/runtime/gateways/file/node/to-array-buffer.ts","kind":"import-statement","original":"./to-array-buffer.js"},{"path":"@adviser/cement","kind":"import-statement","external":true},{"path":"fs/promises","kind":"dynamic-import","external":true}],"format":"esm"}},"outputs":{"dist/fireproof-core/node/mem-filesystem.cjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":3071},"dist/fireproof-core/node/mem-filesystem.cjs":{"imports":[{"path":"memfs","kind":"require-call","external":true}],"exports":[],"entryPoint":"src/runtime/gateways/file/node/mem-filesystem.ts","inputs":{"src/runtime/gateways/file/node/mem-filesystem.ts":{"bytesInOutput":1016},"src/runtime/gateways/file/node/to-array-buffer.ts":{"bytesInOutput":277}},"bytes":2252},"dist/fireproof-core/node/node-filesystem.cjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":4979},"dist/fireproof-core/node/node-filesystem.cjs":{"imports":[{"path":"@adviser/cement","kind":"require-call","external":true},{"path":"fs/promises","kind":"dynamic-import","external":true}],"exports":[],"entryPoint":"src/runtime/gateways/file/node/node-filesystem.ts","inputs":{"src/runtime/gateways/file/node/node-filesystem.ts":{"bytesInOutput":1084},"src/runtime/gateways/file/node/to-array-buffer.ts":{"bytesInOutput":277}},"bytes":2919}}}
@@ -0,0 +1 @@
1
+ {"inputs":{"src/runtime/gateways/file/node/to-array-buffer.ts":{"bytes":313,"imports":[],"format":"esm"},"src/runtime/gateways/file/node/mem-filesystem.ts":{"bytes":1466,"imports":[{"path":"memfs","kind":"import-statement","external":true},{"path":"memfs/lib/node/types/options.js","kind":"import-statement","external":true},{"path":"src/runtime/gateways/file/node/to-array-buffer.ts","kind":"import-statement","original":"./to-array-buffer.js"}],"format":"esm"},"src/runtime/gateways/file/node/node-filesystem.ts":{"bytes":3143,"imports":[{"path":"src/runtime/gateways/file/node/to-array-buffer.ts","kind":"import-statement","original":"./to-array-buffer.js"},{"path":"@adviser/cement","kind":"import-statement","external":true},{"path":"node:fs/promises","kind":"dynamic-import","external":true}],"format":"esm"}},"outputs":{"dist/fireproof-core/node/mem-filesystem.js.map":{"imports":[],"exports":[],"inputs":{},"bytes":2377},"dist/fireproof-core/node/mem-filesystem.js":{"imports":[{"path":"dist/fireproof-core/node/chunk-4A4RAVNS.js","kind":"import-statement"},{"path":"memfs","kind":"import-statement","external":true}],"exports":["MemFileSystem"],"entryPoint":"src/runtime/gateways/file/node/mem-filesystem.ts","inputs":{"src/runtime/gateways/file/node/mem-filesystem.ts":{"bytesInOutput":739}},"bytes":875},"dist/fireproof-core/node/node-filesystem.js.map":{"imports":[],"exports":[],"inputs":{},"bytes":4285},"dist/fireproof-core/node/node-filesystem.js":{"imports":[{"path":"dist/fireproof-core/node/chunk-4A4RAVNS.js","kind":"import-statement"},{"path":"@adviser/cement","kind":"import-statement","external":true},{"path":"node:fs/promises","kind":"dynamic-import","external":true}],"exports":["NodeFileSystem"],"entryPoint":"src/runtime/gateways/file/node/node-filesystem.ts","inputs":{"src/runtime/gateways/file/node/node-filesystem.ts":{"bytesInOutput":898}},"bytes":1036},"dist/fireproof-core/node/chunk-4A4RAVNS.js.map":{"imports":[],"exports":[],"inputs":{},"bytes":735},"dist/fireproof-core/node/chunk-4A4RAVNS.js":{"imports":[],"exports":["toArrayBuffer"],"inputs":{"src/runtime/gateways/file/node/to-array-buffer.ts":{"bytesInOutput":277}},"bytes":359}}}
@@ -0,0 +1,86 @@
1
+ "use strict";
2
+ var __create = Object.create;
3
+ var __defProp = Object.defineProperty;
4
+ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
5
+ var __getOwnPropNames = Object.getOwnPropertyNames;
6
+ var __getProtoOf = Object.getPrototypeOf;
7
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
8
+ var __export = (target, all) => {
9
+ for (var name in all)
10
+ __defProp(target, name, { get: all[name], enumerable: true });
11
+ };
12
+ var __copyProps = (to, from, except, desc) => {
13
+ if (from && typeof from === "object" || typeof from === "function") {
14
+ for (let key of __getOwnPropNames(from))
15
+ if (!__hasOwnProp.call(to, key) && key !== except)
16
+ __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
17
+ }
18
+ return to;
19
+ };
20
+ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
21
+ // If the importer is in node compatibility mode or this is not an ESM
22
+ // file that has been converted to a CommonJS file using a Babel-
23
+ // compatible transform (i.e. "__esModule" has not been set), then set
24
+ // "default" to the CommonJS "module.exports" for node compatibility.
25
+ isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
26
+ mod
27
+ ));
28
+ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
29
+
30
+ // src/runtime/gateways/file/node/node-filesystem.ts
31
+ var node_filesystem_exports = {};
32
+ __export(node_filesystem_exports, {
33
+ NodeFileSystem: () => NodeFileSystem
34
+ });
35
+ module.exports = __toCommonJS(node_filesystem_exports);
36
+
37
+ // src/runtime/gateways/file/node/to-array-buffer.ts
38
+ function toArrayBuffer(buffer) {
39
+ if (typeof buffer === "string") {
40
+ buffer = Buffer.from(buffer);
41
+ }
42
+ const ab = new ArrayBuffer(buffer.length);
43
+ const view = new Uint8Array(ab);
44
+ for (let i = 0; i < buffer.length; ++i) {
45
+ view[i] = buffer[i];
46
+ }
47
+ return view;
48
+ }
49
+
50
+ // src/runtime/gateways/file/node/node-filesystem.ts
51
+ var import_cement = require("@adviser/cement");
52
+ var NodeFileSystem = class {
53
+ async start() {
54
+ this.fs = await import("fs/promises");
55
+ return this;
56
+ }
57
+ async mkdir(path, options) {
58
+ return this.fs?.mkdir(path, options);
59
+ }
60
+ async readdir(path, options) {
61
+ return this.fs?.readdir(path, options);
62
+ }
63
+ async rm(path, options) {
64
+ return this.fs?.rm(path, options);
65
+ }
66
+ async copyFile(source, destination) {
67
+ return this.fs?.copyFile(source, destination);
68
+ }
69
+ async readfile(path, options) {
70
+ const ret = await this.fs?.readFile(path, options);
71
+ return toArrayBuffer(ret);
72
+ }
73
+ stat(path) {
74
+ return this.fs?.stat(path);
75
+ }
76
+ async unlink(path) {
77
+ return this.fs?.unlink(path);
78
+ }
79
+ async writefile(path, data) {
80
+ if ((0, import_cement.runtimeFn)().isDeno) {
81
+ return this.fs?.writeFile(path, data);
82
+ }
83
+ return this.fs?.writeFile(path, Buffer.from(data));
84
+ }
85
+ };
86
+ //# sourceMappingURL=node-filesystem.cjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../../../src/runtime/gateways/file/node/node-filesystem.ts","../../../src/runtime/gateways/file/node/to-array-buffer.ts"],"sourcesContent":["import type { PathLike, MakeDirectoryOptions, Stats, ObjectEncodingOptions } from \"node:fs\";\nimport type { mkdir, readdir, rm, copyFile, readFile, stat, unlink, writeFile } from \"node:fs/promises\";\nimport { toArrayBuffer } from \"./to-array-buffer.js\";\nimport type { SysFileSystem } from \"../../../../types.js\";\nimport { runtimeFn } from \"@adviser/cement\";\n\nexport class NodeFileSystem implements SysFileSystem {\n fs?: {\n mkdir: typeof mkdir;\n readdir: typeof readdir;\n rm: typeof rm;\n copyFile: typeof copyFile;\n readFile: typeof readFile;\n stat: typeof stat;\n unlink: typeof unlink;\n writeFile: typeof writeFile;\n };\n\n async start(): Promise<SysFileSystem> {\n this.fs = await import(\"node:fs/promises\");\n return this;\n }\n async mkdir(path: PathLike, options?: { recursive: boolean }): Promise<string | undefined> {\n return this.fs?.mkdir(path, options);\n }\n async readdir(path: PathLike, options?: ObjectEncodingOptions): Promise<string[]> {\n return this.fs?.readdir(path, options) as Promise<string[]>;\n }\n async rm(path: PathLike, options?: MakeDirectoryOptions & { recursive: boolean }): Promise<void> {\n return this.fs?.rm(path, options);\n }\n async copyFile(source: PathLike, destination: PathLike): Promise<void> {\n return this.fs?.copyFile(source, destination);\n }\n async readfile(path: PathLike, options?: { encoding: BufferEncoding; flag?: string }): Promise<Uint8Array> {\n const ret = (await this.fs?.readFile(path, options)) as Buffer;\n return toArrayBuffer(ret);\n }\n stat(path: PathLike): Promise<Stats> {\n return this.fs?.stat(path) as Promise<Stats>;\n }\n async unlink(path: PathLike): Promise<void> {\n return this.fs?.unlink(path);\n }\n async writefile(path: PathLike, data: Uint8Array | string): Promise<void> {\n if (runtimeFn().isDeno) {\n return this.fs?.writeFile(path, data);\n }\n return this.fs?.writeFile(path, Buffer.from(data));\n }\n}\n\n// import { type NodeMap, join } from \"../../sys-container.js\";\n// import type { ObjectEncodingOptions, PathLike } from \"fs\";\n// import * as fs from \"fs/promises\";\n// import * as path from \"path\";\n// import * as os from \"os\";\n// import * as url from \"url\";\n// import { toArrayBuffer } from \"./utils.js\";\n\n// export async function createNodeSysContainer(): Promise<NodeMap> {\n// // const nodePath = \"node:path\";\n// // const nodeOS = \"node:os\";\n// // const nodeURL = \"node:url\";\n// // const nodeFS = \"node:fs\";\n// // const fs = (await import(\"node:fs\")).promises;\n// // const assert = \"assert\";\n// // const path = await import(\"node:path\");\n// return {\n// state: \"node\",\n// ...path,\n// // ...(await import(\"node:os\")),\n// // ...(await import(\"node:url\")),\n// ...os,\n// ...url,\n// ...fs,\n// join,\n// stat: fs.stat as NodeMap[\"stat\"],\n// readdir: fs.readdir as NodeMap[\"readdir\"],\n// readfile: async (path: PathLike, options?: ObjectEncodingOptions): Promise<Uint8Array> => {\n// const rs = await fs.readFile(path, options);\n// return toArrayBuffer(rs);\n// },\n// writefile: fs.writeFile as NodeMap[\"writefile\"],\n// };\n// }\n","export function toArrayBuffer(buffer: Buffer | string): Uint8Array {\n if (typeof buffer === \"string\") {\n buffer = Buffer.from(buffer);\n }\n const ab = new ArrayBuffer(buffer.length);\n const view = new Uint8Array(ab);\n for (let i = 0; i < buffer.length; ++i) {\n view[i] = buffer[i];\n }\n return view;\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;;;ACAO,SAAS,cAAc,QAAqC;AACjE,MAAI,OAAO,WAAW,UAAU;AAC9B,aAAS,OAAO,KAAK,MAAM;AAAA,EAC7B;AACA,QAAM,KAAK,IAAI,YAAY,OAAO,MAAM;AACxC,QAAM,OAAO,IAAI,WAAW,EAAE;AAC9B,WAAS,IAAI,GAAG,IAAI,OAAO,QAAQ,EAAE,GAAG;AACtC,SAAK,CAAC,IAAI,OAAO,CAAC;AAAA,EACpB;AACA,SAAO;AACT;;;ADNA,oBAA0B;AAEnB,IAAM,iBAAN,MAA8C;AAAA,EAYnD,MAAM,QAAgC;AACpC,SAAK,KAAK,MAAM,OAAO,aAAkB;AACzC,WAAO;AAAA,EACT;AAAA,EACA,MAAM,MAAM,MAAgB,SAA+D;AACzF,WAAO,KAAK,IAAI,MAAM,MAAM,OAAO;AAAA,EACrC;AAAA,EACA,MAAM,QAAQ,MAAgB,SAAoD;AAChF,WAAO,KAAK,IAAI,QAAQ,MAAM,OAAO;AAAA,EACvC;AAAA,EACA,MAAM,GAAG,MAAgB,SAAwE;AAC/F,WAAO,KAAK,IAAI,GAAG,MAAM,OAAO;AAAA,EAClC;AAAA,EACA,MAAM,SAAS,QAAkB,aAAsC;AACrE,WAAO,KAAK,IAAI,SAAS,QAAQ,WAAW;AAAA,EAC9C;AAAA,EACA,MAAM,SAAS,MAAgB,SAA4E;AACzG,UAAM,MAAO,MAAM,KAAK,IAAI,SAAS,MAAM,OAAO;AAClD,WAAO,cAAc,GAAG;AAAA,EAC1B;AAAA,EACA,KAAK,MAAgC;AACnC,WAAO,KAAK,IAAI,KAAK,IAAI;AAAA,EAC3B;AAAA,EACA,MAAM,OAAO,MAA+B;AAC1C,WAAO,KAAK,IAAI,OAAO,IAAI;AAAA,EAC7B;AAAA,EACA,MAAM,UAAU,MAAgB,MAA0C;AACxE,YAAI,yBAAU,EAAE,QAAQ;AACtB,aAAO,KAAK,IAAI,UAAU,MAAM,IAAI;AAAA,IACtC;AACA,WAAO,KAAK,IAAI,UAAU,MAAM,OAAO,KAAK,IAAI,CAAC;AAAA,EACnD;AACF;","names":[]}
@@ -0,0 +1,36 @@
1
+ import { PathLike, ObjectEncodingOptions, MakeDirectoryOptions, Stats } from 'node:fs';
2
+ import { mkdir, readdir, rm, copyFile, readFile, stat, unlink, writeFile } from 'node:fs/promises';
3
+ import { S as SysFileSystem } from './types-DARSfXlb.cjs';
4
+ import 'fs';
5
+
6
+ declare class NodeFileSystem implements SysFileSystem {
7
+ fs?: {
8
+ mkdir: typeof mkdir;
9
+ readdir: typeof readdir;
10
+ rm: typeof rm;
11
+ copyFile: typeof copyFile;
12
+ readFile: typeof readFile;
13
+ stat: typeof stat;
14
+ unlink: typeof unlink;
15
+ writeFile: typeof writeFile;
16
+ };
17
+ start(): Promise<SysFileSystem>;
18
+ mkdir(path: PathLike, options?: {
19
+ recursive: boolean;
20
+ }): Promise<string | undefined>;
21
+ readdir(path: PathLike, options?: ObjectEncodingOptions): Promise<string[]>;
22
+ rm(path: PathLike, options?: MakeDirectoryOptions & {
23
+ recursive: boolean;
24
+ }): Promise<void>;
25
+ copyFile(source: PathLike, destination: PathLike): Promise<void>;
26
+ readfile(path: PathLike, options?: {
27
+ encoding: BufferEncoding;
28
+ flag?: string;
29
+ }): Promise<Uint8Array>;
30
+ stat(path: PathLike): Promise<Stats>;
31
+ unlink(path: PathLike): Promise<void>;
32
+ writefile(path: PathLike, data: Uint8Array | string): Promise<void>;
33
+ }
34
+
35
+ export { NodeFileSystem };
36
+ declare module '@fireproof/core/node'
@@ -0,0 +1,36 @@
1
+ import { PathLike, ObjectEncodingOptions, MakeDirectoryOptions, Stats } from 'node:fs';
2
+ import { mkdir, readdir, rm, copyFile, readFile, stat, unlink, writeFile } from 'node:fs/promises';
3
+ import { S as SysFileSystem } from './types-DARSfXlb.js';
4
+ import 'fs';
5
+
6
+ declare class NodeFileSystem implements SysFileSystem {
7
+ fs?: {
8
+ mkdir: typeof mkdir;
9
+ readdir: typeof readdir;
10
+ rm: typeof rm;
11
+ copyFile: typeof copyFile;
12
+ readFile: typeof readFile;
13
+ stat: typeof stat;
14
+ unlink: typeof unlink;
15
+ writeFile: typeof writeFile;
16
+ };
17
+ start(): Promise<SysFileSystem>;
18
+ mkdir(path: PathLike, options?: {
19
+ recursive: boolean;
20
+ }): Promise<string | undefined>;
21
+ readdir(path: PathLike, options?: ObjectEncodingOptions): Promise<string[]>;
22
+ rm(path: PathLike, options?: MakeDirectoryOptions & {
23
+ recursive: boolean;
24
+ }): Promise<void>;
25
+ copyFile(source: PathLike, destination: PathLike): Promise<void>;
26
+ readfile(path: PathLike, options?: {
27
+ encoding: BufferEncoding;
28
+ flag?: string;
29
+ }): Promise<Uint8Array>;
30
+ stat(path: PathLike): Promise<Stats>;
31
+ unlink(path: PathLike): Promise<void>;
32
+ writefile(path: PathLike, data: Uint8Array | string): Promise<void>;
33
+ }
34
+
35
+ export { NodeFileSystem };
36
+ declare module '@fireproof/core/node'
@@ -1,9 +1,8 @@
1
1
  import {
2
2
  toArrayBuffer
3
- } from "./chunk-LNFBDD6E.js";
4
- import "./chunk-GZANCVTS.js";
3
+ } from "./chunk-4A4RAVNS.js";
5
4
 
6
- // src/runtime/gateways/file/node-filesystem@skip-iife.ts
5
+ // src/runtime/gateways/file/node/node-filesystem.ts
7
6
  import { runtimeFn } from "@adviser/cement";
8
7
  var NodeFileSystem = class {
9
8
  async start() {
@@ -42,4 +41,4 @@ var NodeFileSystem = class {
42
41
  export {
43
42
  NodeFileSystem
44
43
  };
45
- //# sourceMappingURL=node-filesystem@skip-iife-O74VAABQ.js.map
44
+ //# sourceMappingURL=node-filesystem.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../../../src/runtime/gateways/file/node/node-filesystem.ts"],"sourcesContent":["import type { PathLike, MakeDirectoryOptions, Stats, ObjectEncodingOptions } from \"node:fs\";\nimport type { mkdir, readdir, rm, copyFile, readFile, stat, unlink, writeFile } from \"node:fs/promises\";\nimport { toArrayBuffer } from \"./to-array-buffer.js\";\nimport type { SysFileSystem } from \"../../../../types.js\";\nimport { runtimeFn } from \"@adviser/cement\";\n\nexport class NodeFileSystem implements SysFileSystem {\n fs?: {\n mkdir: typeof mkdir;\n readdir: typeof readdir;\n rm: typeof rm;\n copyFile: typeof copyFile;\n readFile: typeof readFile;\n stat: typeof stat;\n unlink: typeof unlink;\n writeFile: typeof writeFile;\n };\n\n async start(): Promise<SysFileSystem> {\n this.fs = await import(\"node:fs/promises\");\n return this;\n }\n async mkdir(path: PathLike, options?: { recursive: boolean }): Promise<string | undefined> {\n return this.fs?.mkdir(path, options);\n }\n async readdir(path: PathLike, options?: ObjectEncodingOptions): Promise<string[]> {\n return this.fs?.readdir(path, options) as Promise<string[]>;\n }\n async rm(path: PathLike, options?: MakeDirectoryOptions & { recursive: boolean }): Promise<void> {\n return this.fs?.rm(path, options);\n }\n async copyFile(source: PathLike, destination: PathLike): Promise<void> {\n return this.fs?.copyFile(source, destination);\n }\n async readfile(path: PathLike, options?: { encoding: BufferEncoding; flag?: string }): Promise<Uint8Array> {\n const ret = (await this.fs?.readFile(path, options)) as Buffer;\n return toArrayBuffer(ret);\n }\n stat(path: PathLike): Promise<Stats> {\n return this.fs?.stat(path) as Promise<Stats>;\n }\n async unlink(path: PathLike): Promise<void> {\n return this.fs?.unlink(path);\n }\n async writefile(path: PathLike, data: Uint8Array | string): Promise<void> {\n if (runtimeFn().isDeno) {\n return this.fs?.writeFile(path, data);\n }\n return this.fs?.writeFile(path, Buffer.from(data));\n }\n}\n\n// import { type NodeMap, join } from \"../../sys-container.js\";\n// import type { ObjectEncodingOptions, PathLike } from \"fs\";\n// import * as fs from \"fs/promises\";\n// import * as path from \"path\";\n// import * as os from \"os\";\n// import * as url from \"url\";\n// import { toArrayBuffer } from \"./utils.js\";\n\n// export async function createNodeSysContainer(): Promise<NodeMap> {\n// // const nodePath = \"node:path\";\n// // const nodeOS = \"node:os\";\n// // const nodeURL = \"node:url\";\n// // const nodeFS = \"node:fs\";\n// // const fs = (await import(\"node:fs\")).promises;\n// // const assert = \"assert\";\n// // const path = await import(\"node:path\");\n// return {\n// state: \"node\",\n// ...path,\n// // ...(await import(\"node:os\")),\n// // ...(await import(\"node:url\")),\n// ...os,\n// ...url,\n// ...fs,\n// join,\n// stat: fs.stat as NodeMap[\"stat\"],\n// readdir: fs.readdir as NodeMap[\"readdir\"],\n// readfile: async (path: PathLike, options?: ObjectEncodingOptions): Promise<Uint8Array> => {\n// const rs = await fs.readFile(path, options);\n// return toArrayBuffer(rs);\n// },\n// writefile: fs.writeFile as NodeMap[\"writefile\"],\n// };\n// }\n"],"mappings":";;;;;AAIA,SAAS,iBAAiB;AAEnB,IAAM,iBAAN,MAA8C;AAAA,EAYnD,MAAM,QAAgC;AACpC,SAAK,KAAK,MAAM,OAAO,kBAAkB;AACzC,WAAO;AAAA,EACT;AAAA,EACA,MAAM,MAAM,MAAgB,SAA+D;AACzF,WAAO,KAAK,IAAI,MAAM,MAAM,OAAO;AAAA,EACrC;AAAA,EACA,MAAM,QAAQ,MAAgB,SAAoD;AAChF,WAAO,KAAK,IAAI,QAAQ,MAAM,OAAO;AAAA,EACvC;AAAA,EACA,MAAM,GAAG,MAAgB,SAAwE;AAC/F,WAAO,KAAK,IAAI,GAAG,MAAM,OAAO;AAAA,EAClC;AAAA,EACA,MAAM,SAAS,QAAkB,aAAsC;AACrE,WAAO,KAAK,IAAI,SAAS,QAAQ,WAAW;AAAA,EAC9C;AAAA,EACA,MAAM,SAAS,MAAgB,SAA4E;AACzG,UAAM,MAAO,MAAM,KAAK,IAAI,SAAS,MAAM,OAAO;AAClD,WAAO,cAAc,GAAG;AAAA,EAC1B;AAAA,EACA,KAAK,MAAgC;AACnC,WAAO,KAAK,IAAI,KAAK,IAAI;AAAA,EAC3B;AAAA,EACA,MAAM,OAAO,MAA+B;AAC1C,WAAO,KAAK,IAAI,OAAO,IAAI;AAAA,EAC7B;AAAA,EACA,MAAM,UAAU,MAAgB,MAA0C;AACxE,QAAI,UAAU,EAAE,QAAQ;AACtB,aAAO,KAAK,IAAI,UAAU,MAAM,IAAI;AAAA,IACtC;AACA,WAAO,KAAK,IAAI,UAAU,MAAM,OAAO,KAAK,IAAI,CAAC;AAAA,EACnD;AACF;","names":[]}
@@ -0,0 +1,23 @@
1
+ import { PathLike, MakeDirectoryOptions, Stats } from 'fs';
2
+
3
+ interface SysFileSystem {
4
+ start(): Promise<SysFileSystem>;
5
+ mkdir(path: PathLike, options?: {
6
+ recursive: boolean;
7
+ }): Promise<string | undefined>;
8
+ readdir(path: PathLike, options?: unknown): Promise<string[]>;
9
+ rm(path: PathLike, options?: MakeDirectoryOptions & {
10
+ recursive: boolean;
11
+ }): Promise<void>;
12
+ copyFile(source: PathLike, destination: PathLike): Promise<void>;
13
+ readfile(path: PathLike, options?: {
14
+ encoding: BufferEncoding;
15
+ flag?: string;
16
+ }): Promise<Uint8Array>;
17
+ stat(path: PathLike): Promise<Stats>;
18
+ unlink(path: PathLike): Promise<void>;
19
+ writefile(path: PathLike, data: Uint8Array | string): Promise<void>;
20
+ }
21
+
22
+ export type { SysFileSystem as S };
23
+ declare module '@fireproof/core/node'
@@ -0,0 +1,23 @@
1
+ import { PathLike, MakeDirectoryOptions, Stats } from 'fs';
2
+
3
+ interface SysFileSystem {
4
+ start(): Promise<SysFileSystem>;
5
+ mkdir(path: PathLike, options?: {
6
+ recursive: boolean;
7
+ }): Promise<string | undefined>;
8
+ readdir(path: PathLike, options?: unknown): Promise<string[]>;
9
+ rm(path: PathLike, options?: MakeDirectoryOptions & {
10
+ recursive: boolean;
11
+ }): Promise<void>;
12
+ copyFile(source: PathLike, destination: PathLike): Promise<void>;
13
+ readfile(path: PathLike, options?: {
14
+ encoding: BufferEncoding;
15
+ flag?: string;
16
+ }): Promise<Uint8Array>;
17
+ stat(path: PathLike): Promise<Stats>;
18
+ unlink(path: PathLike): Promise<void>;
19
+ writefile(path: PathLike, data: Uint8Array | string): Promise<void>;
20
+ }
21
+
22
+ export type { SysFileSystem as S };
23
+ declare module '@fireproof/core/node'
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@fireproof/core",
3
- "version": "0.19.112-dev-web",
3
+ "version": "0.19.112-dev-dyn",
4
4
  "description": "Live database for the web.",
5
5
  "type": "module",
6
6
  "module": "./index.js",
@@ -0,0 +1,13 @@
1
+ import {
2
+ getFileName,
3
+ getFileSystem,
4
+ getPath
5
+ } from "./chunk-PWEDYV5H.js";
6
+ import "./chunk-D4E6UX6S.js";
7
+ import "./chunk-PZ5AY32C.js";
8
+ export {
9
+ getFileName,
10
+ getFileSystem,
11
+ getPath
12
+ };
13
+ //# sourceMappingURL=utils-WS4AZWA7.js.map