@solidrt/flux-types 0.0.4 → 0.0.6

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/index.d.ts +7 -0
  2. package/package.json +1 -1
package/index.d.ts CHANGED
@@ -25,11 +25,18 @@ declare global {
25
25
  stat(): Promise<FluxFileStat>
26
26
  }
27
27
 
28
+ type FluxServeOptions = {
29
+ port: number
30
+ fetch?: (req: Request) => Response | string | Promise<Response | string>
31
+ }
32
+
28
33
  let Flux: {
29
34
  on(event: string, callback: (data: any) => void): () => void
35
+ once(event: string, callback: (data: any) => void): () => void
30
36
  dir(path: string): FluxDir
31
37
  file(path: string): FluxFile
32
38
  write(path: string, data: string | Uint8Array): Promise<void>
39
+ serve(options: FluxServeOptions): void
33
40
  }
34
41
  }
35
42
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@solidrt/flux-types",
3
- "version": "0.0.4",
3
+ "version": "0.0.6",
4
4
  "license": "MIT",
5
5
  "author": "Antoine van Wel",
6
6
  "types": "index.d.ts",