@kosmojs/dev 0.5.0 → 0.5.2
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 +38 -2
- package/package.json +18 -17
- package/pkg/chassis.js +143 -53
- package/pkg/chassis.js.map +1 -1
- package/pkg/index.d.ts +1 -1
- package/pkg/index.js +96 -186
- package/pkg/index.js.map +1 -1
- package/pkg/preview.d.ts +2 -2
- package/pkg/templates/run.d.ts +0 -1
package/pkg/preview.d.ts
CHANGED
|
@@ -4,8 +4,8 @@ type Build = (sourceFolder: SourceFolder) => Promise<void>;
|
|
|
4
4
|
* Preview = production build + watcher + `dist/run.js`.
|
|
5
5
|
*
|
|
6
6
|
* The runner is a child process rather than an in-process import:
|
|
7
|
-
* a fresh process is the only way to reload an ESM graph,
|
|
8
|
-
* what production does - `node dist/run.js`.
|
|
7
|
+
* a fresh process is the only way to reload an ESM graph,
|
|
8
|
+
* and it is exactly what production does - `node dist/run.js`.
|
|
9
9
|
*
|
|
10
10
|
* Watching is chokidar over the `src/<folder>` trees - no Vite server,
|
|
11
11
|
* no module graph: the unit of work is "rebuild this folder", so folder-level
|
package/pkg/templates/run.d.ts
CHANGED
|
@@ -17,7 +17,6 @@
|
|
|
17
17
|
* with the SPA fallback to index.html for unmatched page URLs.
|
|
18
18
|
*
|
|
19
19
|
* Authored as TypeScript, deployed with types stripped;
|
|
20
|
-
* only node builtins are used here: `node:http` runs unchanged on Node, Bun and Deno.
|
|
21
20
|
* */
|
|
22
21
|
import type { IncomingMessage, Server, ServerResponse } from "node:http";
|
|
23
22
|
type NodeListener = (req: IncomingMessage, res: ServerResponse) => void;
|