@junejs/cli 0.0.46 → 0.0.48
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/package.json +2 -2
- package/src/watch.ts +4 -3
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@junejs/cli",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.48",
|
|
4
4
|
"description": "The `june` CLI — dev / build / deploy / gen / info. A thin bin over @junejs/server.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"license": "MIT",
|
|
@@ -21,7 +21,7 @@
|
|
|
21
21
|
},
|
|
22
22
|
"dependencies": {
|
|
23
23
|
"@junejs/core": "^0.0.46",
|
|
24
|
-
"@junejs/server": "^0.0.
|
|
24
|
+
"@junejs/server": "^0.0.45"
|
|
25
25
|
},
|
|
26
26
|
"repository": {
|
|
27
27
|
"type": "git",
|
package/src/watch.ts
CHANGED
|
@@ -10,8 +10,9 @@ import { sep } from "node:path";
|
|
|
10
10
|
|
|
11
11
|
const IGNORED_DIRS = new Set(["node_modules", ".git", "dist", ".june"]);
|
|
12
12
|
|
|
13
|
-
// Exported for tests. `app/_content.*`
|
|
14
|
-
//
|
|
13
|
+
// Exported for tests. Toolchain-generated app artifacts — `app/_content.*` (`june gen`) and
|
|
14
|
+
// `app/_islands.gen.ts` / any top-level `app/*.gen.ts` (rewritten before every bundle) — must be
|
|
15
|
+
// ignored, or watching them loops (regen → write event → regen …).
|
|
15
16
|
export function ignoredPath(file: string): boolean {
|
|
16
17
|
const parts = file.split(sep);
|
|
17
18
|
if (parts.some((p) => IGNORED_DIRS.has(p))) return true;
|
|
@@ -19,7 +20,7 @@ export function ignoredPath(file: string): boolean {
|
|
|
19
20
|
// the supervisor must NOT respawn over a .css edit, or the swap degrades to a
|
|
20
21
|
// full reload. A .tsx edit still restarts (its rendered markup changed too).
|
|
21
22
|
if (file.endsWith(".css")) return true;
|
|
22
|
-
return parts.length === 2 && parts[0] === "app" && /^_content\.[^/]+$/.test(parts[1]!);
|
|
23
|
+
return parts.length === 2 && parts[0] === "app" && (/^_content\.[^/]+$/.test(parts[1]!) || parts[1]!.endsWith(".gen.ts"));
|
|
23
24
|
}
|
|
24
25
|
|
|
25
26
|
export function superviseDev(root: string): undefined {
|