eddev 2.3.31 → 2.4.0-beta.1
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/dist/app/entry/ssr-root-client.d.ts +0 -2
- package/dist/app/entry/ssr-root-client.d.ts.map +1 -1
- package/dist/app/lib/blocks/block-debugger.d.ts.map +1 -1
- package/dist/app/lib/blocks/block-debugger.js +19 -2
- package/dist/app/lib/devtools/components/panels/StructurePanel.js +1 -1
- package/dist/app/server/assets.d.ts +45 -0
- package/dist/app/server/assets.d.ts.map +1 -0
- package/dist/app/server/assets.js +15 -0
- package/dist/app/server/index.d.ts +4 -0
- package/dist/app/server/index.d.ts.map +1 -1
- package/dist/app/server/index.js +3 -0
- package/dist/app/server/proxy-wp-admin.d.ts +6 -2
- package/dist/app/server/proxy-wp-admin.d.ts.map +1 -1
- package/dist/app/server/proxy-wp-admin.js +29 -57
- package/dist/app/server/render-ssr-page.d.ts +2 -6
- package/dist/app/server/render-ssr-page.d.ts.map +1 -1
- package/dist/app/server/render-ssr-page.js +9 -8
- package/dist/app/server/rpc-handler.d.ts +14 -0
- package/dist/app/server/rpc-handler.d.ts.map +1 -0
- package/dist/app/server/rpc-handler.js +63 -0
- package/dist/app/server/server-app.d.ts +22 -0
- package/dist/app/server/server-app.d.ts.map +1 -0
- package/dist/app/server/server-app.js +186 -0
- package/dist/app/server/server-context.d.ts +5 -5
- package/dist/app/server/server-context.d.ts.map +1 -1
- package/dist/app/server/server-context.js +9 -8
- package/dist/app/server/utils/fetch-origin.d.ts +13 -0
- package/dist/app/server/utils/fetch-origin.d.ts.map +1 -0
- package/dist/app/server/utils/fetch-origin.js +21 -0
- package/dist/app/server/utils/request.d.ts +20 -0
- package/dist/app/server/utils/request.d.ts.map +1 -0
- package/dist/app/server/utils/request.js +60 -0
- package/dist/node/cli/cli-worker.d.ts +10 -6
- package/dist/node/cli/cli-worker.d.ts.map +1 -1
- package/dist/node/cli/cli-worker.js +7 -14
- package/dist/node/cli/cli.js +37 -43
- package/dist/node/cli/display/CLIApp.d.ts +2 -4
- package/dist/node/cli/display/CLIApp.d.ts.map +1 -1
- package/dist/node/cli/display/CLIApp.js +2 -3
- package/dist/node/cli/version.d.ts +1 -1
- package/dist/node/cli/version.d.ts.map +1 -1
- package/dist/node/cli/version.js +1 -1
- package/dist/node/compiler/app-codegen.d.ts +18 -0
- package/dist/node/compiler/app-codegen.d.ts.map +1 -0
- package/dist/node/compiler/app-codegen.js +473 -0
- package/dist/node/compiler/build-serverless.d.ts +16 -0
- package/dist/node/compiler/build-serverless.d.ts.map +1 -0
- package/dist/node/compiler/build-serverless.js +40 -0
- package/dist/node/compiler/bundler.spa.d.ts +33 -0
- package/dist/node/compiler/bundler.spa.d.ts.map +1 -0
- package/dist/node/compiler/bundler.spa.js +59 -0
- package/dist/node/compiler/dev-css-links.d.ts +25 -0
- package/dist/node/compiler/dev-css-links.d.ts.map +1 -0
- package/dist/node/compiler/dev-css-links.js +87 -0
- package/dist/node/compiler/dev-server.d.ts +2 -0
- package/dist/node/compiler/dev-server.d.ts.map +1 -1
- package/dist/node/compiler/dev-server.js +43 -75
- package/dist/node/compiler/get-vite-config.d.ts +37 -6
- package/dist/node/compiler/get-vite-config.d.ts.map +1 -1
- package/dist/node/compiler/get-vite-config.js +113 -121
- package/dist/node/compiler/serverless-app.d.ts +35 -0
- package/dist/node/compiler/serverless-app.d.ts.map +1 -0
- package/dist/node/compiler/serverless-app.js +332 -0
- package/dist/node/compiler/transforms/block-meta.d.ts +10 -0
- package/dist/node/compiler/transforms/block-meta.d.ts.map +1 -0
- package/dist/node/compiler/transforms/block-meta.js +27 -0
- package/dist/node/compiler/transforms/component-names.d.ts +19 -0
- package/dist/node/compiler/transforms/component-names.d.ts.map +1 -0
- package/dist/node/compiler/transforms/component-names.js +45 -0
- package/dist/node/compiler/transforms/index.d.ts +36 -0
- package/dist/node/compiler/transforms/index.d.ts.map +1 -0
- package/dist/node/compiler/transforms/index.js +80 -0
- package/dist/node/compiler/transforms/types.d.ts +48 -0
- package/dist/node/compiler/transforms/types.d.ts.map +1 -0
- package/dist/node/compiler/transforms/types.js +1 -0
- package/dist/node/project/config.d.ts +1 -1
- package/dist/node/project/config.d.ts.map +1 -1
- package/dist/node/project/config.js +1 -1
- package/dist/node/project/env.js +1 -1
- package/dist/node/project/project-log.d.ts +7 -0
- package/dist/node/project/project-log.d.ts.map +1 -0
- package/dist/node/project/project-log.js +6 -0
- package/dist/node/project/project.d.ts +2 -2
- package/dist/node/project/project.d.ts.map +1 -1
- package/dist/node/project/project.js +3 -3
- package/dist/node/utils/fs.d.ts +70 -69
- package/dist/node/utils/fs.d.ts.map +1 -1
- package/package.json +12 -13
- package/skills/eddev/docs/devtool/cli.mdx +10 -8
- package/tsconfig.node.json +17 -5
- package/types.env.d.ts +1 -1
- package/dist/node/compiler/build-vinxi.d.ts +0 -9
- package/dist/node/compiler/build-vinxi.d.ts.map +0 -1
- package/dist/node/compiler/build-vinxi.js +0 -39
- package/dist/node/compiler/bundler.admin.d.ts +0 -14
- package/dist/node/compiler/bundler.admin.d.ts.map +0 -1
- package/dist/node/compiler/bundler.admin.js +0 -37
- package/dist/node/compiler/bundler.frontend.d.ts +0 -15
- package/dist/node/compiler/bundler.frontend.d.ts.map +0 -1
- package/dist/node/compiler/bundler.frontend.js +0 -51
- package/dist/node/compiler/vinxi-app.d.ts +0 -23
- package/dist/node/compiler/vinxi-app.d.ts.map +0 -1
- package/dist/node/compiler/vinxi-app.js +0 -261
- package/dist/node/compiler/vinxi-codegen.d.ts +0 -13
- package/dist/node/compiler/vinxi-codegen.d.ts.map +0 -1
- package/dist/node/compiler/vinxi-codegen.js +0 -764
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import type { Project } from "./project.js";
|
|
2
|
+
/**
|
|
3
|
+
* The project log. Kept in its own module so runtime code that only needs environment helpers
|
|
4
|
+
* (eg. `fetchWP` on the server) doesn't import the whole project loader and its dependencies.
|
|
5
|
+
*/
|
|
6
|
+
export declare const projectLog: import("../utils/stateful-log.js").StatefulLog<Project>;
|
|
7
|
+
//# sourceMappingURL=project-log.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"project-log.d.ts","sourceRoot":"","sources":["../../../src/node/project/project-log.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,cAAc,CAAA;AAE3C;;;GAGG;AACH,eAAO,MAAM,UAAU,yDAA+C,CAAA"}
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import { createConsole } from "../utils/stateful-log.js";
|
|
2
|
+
/**
|
|
3
|
+
* The project log. Kept in its own module so runtime code that only needs environment helpers
|
|
4
|
+
* (eg. `fetchWP` on the server) doesn't import the whole project loader and its dependencies.
|
|
5
|
+
*/
|
|
6
|
+
export const projectLog = createConsole("Project", "project");
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { projectLog } from "./project-log.js";
|
|
1
2
|
import { EDConfig } from "./config.js";
|
|
2
3
|
import { BlockManifestGenerator } from "./manifest/block-manifest.js";
|
|
3
4
|
import { FieldManifestGenerator } from "./manifest/field-manifest.js";
|
|
@@ -5,7 +6,7 @@ import { RouteManifestGenerator } from "./manifest/routes-manifest.js";
|
|
|
5
6
|
import { ViewManifestGenerator } from "./manifest/view-manifest.js";
|
|
6
7
|
import { WidgetManifestGenerator } from "./manifest/widget-manifest.js";
|
|
7
8
|
import { WPInfo } from "./wp-info.js";
|
|
8
|
-
export
|
|
9
|
+
export { projectLog };
|
|
9
10
|
type ProjectArgs = {
|
|
10
11
|
rootDir: string;
|
|
11
12
|
reportPluginCompatibility?: boolean;
|
|
@@ -68,5 +69,4 @@ export declare class Project {
|
|
|
68
69
|
}>;
|
|
69
70
|
static create(args: ProjectArgs): Promise<Project>;
|
|
70
71
|
}
|
|
71
|
-
export {};
|
|
72
72
|
//# sourceMappingURL=project.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"project.d.ts","sourceRoot":"","sources":["../../../src/node/project/project.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"project.d.ts","sourceRoot":"","sources":["../../../src/node/project/project.ts"],"names":[],"mappings":"AAKA,OAAO,EAAE,UAAU,EAAE,MAAM,kBAAkB,CAAA;AAC7C,OAAO,EAAgB,QAAQ,EAAE,MAAM,aAAa,CAAA;AAEpD,OAAO,EAAE,sBAAsB,EAAqB,MAAM,8BAA8B,CAAA;AACxF,OAAO,EAAE,sBAAsB,EAAqB,MAAM,8BAA8B,CAAA;AACxF,OAAO,EAAE,sBAAsB,EAAqB,MAAM,+BAA+B,CAAA;AACzF,OAAO,EAAE,qBAAqB,EAAoB,MAAM,6BAA6B,CAAA;AACrF,OAAO,EAAE,uBAAuB,EAAsB,MAAM,+BAA+B,CAAA;AAC3F,OAAO,EAAE,MAAM,EAAE,MAAM,cAAc,CAAA;AAMrC,OAAO,EAAE,UAAU,EAAE,CAAA;AAErB,KAAK,WAAW,GAAG;IACjB,OAAO,EAAE,MAAM,CAAA;IACf,yBAAyB,CAAC,EAAE,OAAO,CAAA;CACpC,CAAA;AAED;;;GAGG;AACH,qBAAa,OAAO;IAClB,OAAO,SAAK;IACZ,SAAS,SAAK;IACd,SAAS,SAAK;IACd,OAAO,SAAK;IACZ,UAAU,SAAK;IACf,MAAM,SAAK;IAEX,MAAM,CAAC,EAAE,QAAQ,CAAA;IAEjB,YAAY,SAAoB;IAChC,MAAM,EAAG,sBAAsB,CAAA;IAC/B,KAAK,EAAG,qBAAqB,CAAA;IAC7B,MAAM,EAAG,sBAAsB,CAAA;IAC/B,OAAO,EAAG,uBAAuB,CAAA;IACjC,YAAY,EAAG,sBAAsB,CAAA;IACrC,EAAE,EAAG,MAAM,CAAA;IAEX,yBAAyB,UAAQ;IAEjC,OAAO;IAYD,kBAAkB,IAAI,OAAO,CAAC;QAAE,OAAO,EAAE,IAAI,CAAA;KAAE,GAAG;QAAE,OAAO,EAAE,KAAK,CAAC;QAAC,OAAO,EAAE,MAAM,CAAA;KAAE,CAAC;YA4B9E,IAAI;IAmEZ,kBAAkB;IAUxB,iBAAiB;IAkBX,gBAAgB,CAAC,KAAK,GAAE,OAAe;;;;;;;;;;;;;;;;;;;;;;;;;;WAKhC,MAAM,CAAC,IAAI,EAAE,WAAW;CAKtC"}
|
|
@@ -3,7 +3,7 @@ import { relative, resolve } from "path";
|
|
|
3
3
|
import { undent } from "undent";
|
|
4
4
|
import { getRepoInfo } from "../utils/get-repo-info.js";
|
|
5
5
|
import { isDeploying } from "../utils/is-deploying.js";
|
|
6
|
-
import {
|
|
6
|
+
import { projectLog } from "./project-log.js";
|
|
7
7
|
import { Configurator } from "./config.js";
|
|
8
8
|
import { ProjectEnvUtils } from "./env.js";
|
|
9
9
|
import { loadBlockManifest } from "./manifest/block-manifest.js";
|
|
@@ -13,8 +13,8 @@ import { loadViewManifest } from "./manifest/view-manifest.js";
|
|
|
13
13
|
import { loadWidgetManifest } from "./manifest/widget-manifest.js";
|
|
14
14
|
import { WPInfo } from "./wp-info.js";
|
|
15
15
|
import { fs } from "../utils/fs.js";
|
|
16
|
-
const console =
|
|
17
|
-
export
|
|
16
|
+
const console = projectLog;
|
|
17
|
+
export { projectLog };
|
|
18
18
|
/**
|
|
19
19
|
* This class represents a single app project created using the stack.
|
|
20
20
|
* It has methods and properties that are useful for working with the project.
|
package/dist/node/utils/fs.d.ts
CHANGED
|
@@ -6,109 +6,110 @@ export declare const fs: {
|
|
|
6
6
|
readJson: (path: string) => Promise<any>;
|
|
7
7
|
exists: (path: string) => Promise<boolean>;
|
|
8
8
|
mkdirp: (path: string) => Promise<void>;
|
|
9
|
-
access(path: import("fs").PathLike, mode?: number): Promise<void>;
|
|
10
|
-
copyFile(src: import("fs").PathLike, dest: import("fs").PathLike, mode?: number): Promise<void>;
|
|
11
|
-
open(path: import("fs").PathLike, flags?: string | number, mode?: import("fs").Mode): Promise<nodeFs.FileHandle>;
|
|
12
|
-
rename(oldPath: import("fs").PathLike, newPath: import("fs").PathLike): Promise<void>;
|
|
13
|
-
truncate(path: import("fs").PathLike, len?: number): Promise<void>;
|
|
14
|
-
rmdir(path: import("fs").PathLike, options?: import("fs").RmDirOptions): Promise<void>;
|
|
15
|
-
rm(path: import("fs").PathLike, options?: import("fs").RmOptions): Promise<void>;
|
|
16
|
-
mkdir(path: import("fs").PathLike, options: import("fs").MakeDirectoryOptions & {
|
|
9
|
+
access(path: import("node:fs").PathLike, mode?: number): Promise<void>;
|
|
10
|
+
copyFile(src: import("node:fs").PathLike, dest: import("node:fs").PathLike, mode?: number): Promise<void>;
|
|
11
|
+
open(path: import("node:fs").PathLike, flags?: string | number, mode?: import("node:fs").Mode): Promise<nodeFs.FileHandle>;
|
|
12
|
+
rename(oldPath: import("node:fs").PathLike, newPath: import("node:fs").PathLike): Promise<void>;
|
|
13
|
+
truncate(path: import("node:fs").PathLike, len?: number): Promise<void>;
|
|
14
|
+
rmdir(path: import("node:fs").PathLike, options?: import("node:fs").RmDirOptions): Promise<void>;
|
|
15
|
+
rm(path: import("node:fs").PathLike, options?: import("node:fs").RmOptions): Promise<void>;
|
|
16
|
+
mkdir(path: import("node:fs").PathLike, options: import("node:fs").MakeDirectoryOptions & {
|
|
17
17
|
recursive: true;
|
|
18
18
|
}): Promise<string | undefined>;
|
|
19
|
-
mkdir(path: import("fs").PathLike, options?: import("fs").Mode | (import("fs").MakeDirectoryOptions & {
|
|
19
|
+
mkdir(path: import("node:fs").PathLike, options?: import("node:fs").Mode | (import("node:fs").MakeDirectoryOptions & {
|
|
20
20
|
recursive?: false | undefined;
|
|
21
21
|
}) | null): Promise<void>;
|
|
22
|
-
mkdir(path: import("fs").PathLike, options?: import("fs").Mode | import("fs").MakeDirectoryOptions | null): Promise<string | undefined>;
|
|
23
|
-
readdir(path: import("fs").PathLike, options?: (import("fs").ObjectEncodingOptions & {
|
|
22
|
+
mkdir(path: import("node:fs").PathLike, options?: import("node:fs").Mode | import("node:fs").MakeDirectoryOptions | null): Promise<string | undefined>;
|
|
23
|
+
readdir(path: import("node:fs").PathLike, options?: (import("node:fs").ObjectEncodingOptions & {
|
|
24
24
|
withFileTypes?: false | undefined;
|
|
25
25
|
recursive?: boolean | undefined;
|
|
26
26
|
}) | BufferEncoding | null): Promise<string[]>;
|
|
27
|
-
readdir(path: import("fs").PathLike, options: {
|
|
27
|
+
readdir(path: import("node:fs").PathLike, options: {
|
|
28
28
|
encoding: "buffer";
|
|
29
29
|
withFileTypes?: false | undefined;
|
|
30
30
|
recursive?: boolean | undefined;
|
|
31
31
|
} | "buffer"): Promise<NonSharedBuffer[]>;
|
|
32
|
-
readdir(path: import("fs").PathLike, options?: (import("fs").ObjectEncodingOptions & {
|
|
32
|
+
readdir(path: import("node:fs").PathLike, options?: (import("node:fs").ObjectEncodingOptions & {
|
|
33
33
|
withFileTypes?: false | undefined;
|
|
34
34
|
recursive?: boolean | undefined;
|
|
35
35
|
}) | BufferEncoding | null): Promise<string[] | NonSharedBuffer[]>;
|
|
36
|
-
readdir(path: import("fs").PathLike, options: import("fs").ObjectEncodingOptions & {
|
|
36
|
+
readdir(path: import("node:fs").PathLike, options: import("node:fs").ObjectEncodingOptions & {
|
|
37
37
|
withFileTypes: true;
|
|
38
38
|
recursive?: boolean | undefined;
|
|
39
|
-
}): Promise<import("fs").Dirent[]>;
|
|
40
|
-
readdir(path: import("fs").PathLike, options: {
|
|
39
|
+
}): Promise<import("node:fs").Dirent[]>;
|
|
40
|
+
readdir(path: import("node:fs").PathLike, options: {
|
|
41
41
|
encoding: "buffer";
|
|
42
42
|
withFileTypes: true;
|
|
43
43
|
recursive?: boolean | undefined;
|
|
44
|
-
}): Promise<import("fs").Dirent<NonSharedBuffer>[]>;
|
|
45
|
-
readlink(path: import("fs").PathLike, options?: import("fs").ObjectEncodingOptions | BufferEncoding | null): Promise<string>;
|
|
46
|
-
readlink(path: import("fs").PathLike, options: import("fs").BufferEncodingOption): Promise<NonSharedBuffer>;
|
|
47
|
-
readlink(path: import("fs").PathLike, options?: import("fs").ObjectEncodingOptions | string | null): Promise<string | NonSharedBuffer>;
|
|
48
|
-
symlink(target: import("fs").PathLike, path: import("fs").PathLike, type?: string | null): Promise<void>;
|
|
49
|
-
lstat(path: import("fs").PathLike, opts?: import("fs").StatOptions & {
|
|
44
|
+
}): Promise<import("node:fs").Dirent<NonSharedBuffer>[]>;
|
|
45
|
+
readlink(path: import("node:fs").PathLike, options?: import("node:fs").ObjectEncodingOptions | BufferEncoding | null): Promise<string>;
|
|
46
|
+
readlink(path: import("node:fs").PathLike, options: import("node:fs").BufferEncodingOption): Promise<NonSharedBuffer>;
|
|
47
|
+
readlink(path: import("node:fs").PathLike, options?: import("node:fs").ObjectEncodingOptions | string | null): Promise<string | NonSharedBuffer>;
|
|
48
|
+
symlink(target: import("node:fs").PathLike, path: import("node:fs").PathLike, type?: string | null): Promise<void>;
|
|
49
|
+
lstat(path: import("node:fs").PathLike, opts?: import("node:fs").StatOptions & {
|
|
50
50
|
bigint?: false | undefined;
|
|
51
|
-
}): Promise<import("fs").Stats>;
|
|
52
|
-
lstat(path: import("fs").PathLike, opts: import("fs").StatOptions & {
|
|
51
|
+
}): Promise<import("node:fs").Stats>;
|
|
52
|
+
lstat(path: import("node:fs").PathLike, opts: import("node:fs").StatOptions & {
|
|
53
53
|
bigint: true;
|
|
54
|
-
}): Promise<import("fs").BigIntStats>;
|
|
55
|
-
lstat(path: import("fs").PathLike, opts?: import("fs").StatOptions): Promise<import("fs").Stats | import("fs").BigIntStats>;
|
|
56
|
-
stat(path: import("fs").PathLike, opts?: import("fs").StatOptions & {
|
|
54
|
+
}): Promise<import("node:fs").BigIntStats>;
|
|
55
|
+
lstat(path: import("node:fs").PathLike, opts?: import("node:fs").StatOptions): Promise<import("node:fs").Stats | import("node:fs").BigIntStats>;
|
|
56
|
+
stat(path: import("node:fs").PathLike, opts?: import("node:fs").StatOptions & {
|
|
57
57
|
bigint?: false | undefined;
|
|
58
|
-
}): Promise<import("fs").Stats>;
|
|
59
|
-
stat(path: import("fs").PathLike, opts: import("fs").StatOptions & {
|
|
58
|
+
}): Promise<import("node:fs").Stats>;
|
|
59
|
+
stat(path: import("node:fs").PathLike, opts: import("node:fs").StatOptions & {
|
|
60
60
|
bigint: true;
|
|
61
|
-
}): Promise<import("fs").BigIntStats>;
|
|
62
|
-
stat(path: import("fs").PathLike, opts?: import("fs").StatOptions): Promise<import("fs").Stats | import("fs").BigIntStats>;
|
|
63
|
-
statfs(path: import("fs").PathLike, opts?: import("fs").StatFsOptions & {
|
|
61
|
+
}): Promise<import("node:fs").BigIntStats>;
|
|
62
|
+
stat(path: import("node:fs").PathLike, opts?: import("node:fs").StatOptions): Promise<import("node:fs").Stats | import("node:fs").BigIntStats>;
|
|
63
|
+
statfs(path: import("node:fs").PathLike, opts?: import("node:fs").StatFsOptions & {
|
|
64
64
|
bigint?: false | undefined;
|
|
65
|
-
}): Promise<import("fs").StatsFs>;
|
|
66
|
-
statfs(path: import("fs").PathLike, opts: import("fs").StatFsOptions & {
|
|
65
|
+
}): Promise<import("node:fs").StatsFs>;
|
|
66
|
+
statfs(path: import("node:fs").PathLike, opts: import("node:fs").StatFsOptions & {
|
|
67
67
|
bigint: true;
|
|
68
|
-
}): Promise<import("fs").BigIntStatsFs>;
|
|
69
|
-
statfs(path: import("fs").PathLike, opts?: import("fs").StatFsOptions): Promise<import("fs").StatsFs | import("fs").BigIntStatsFs>;
|
|
70
|
-
link(existingPath: import("fs").PathLike, newPath: import("fs").PathLike): Promise<void>;
|
|
71
|
-
unlink(path: import("fs").PathLike): Promise<void>;
|
|
72
|
-
chmod(path: import("fs").PathLike, mode: import("fs").Mode): Promise<void>;
|
|
73
|
-
lchmod(path: import("fs").PathLike, mode: import("fs").Mode): Promise<void>;
|
|
74
|
-
lchown(path: import("fs").PathLike, uid: number, gid: number): Promise<void>;
|
|
75
|
-
lutimes(path: import("fs").PathLike, atime: import("fs").TimeLike, mtime: import("fs").TimeLike): Promise<void>;
|
|
76
|
-
chown(path: import("fs").PathLike, uid: number, gid: number): Promise<void>;
|
|
77
|
-
utimes(path: import("fs").PathLike, atime: import("fs").TimeLike, mtime: import("fs").TimeLike): Promise<void>;
|
|
78
|
-
realpath(path: import("fs").PathLike, options?: import("fs").ObjectEncodingOptions | BufferEncoding | null): Promise<string>;
|
|
79
|
-
realpath(path: import("fs").PathLike, options: import("fs").BufferEncodingOption): Promise<NonSharedBuffer>;
|
|
80
|
-
realpath(path: import("fs").PathLike, options?: import("fs").ObjectEncodingOptions | BufferEncoding | null): Promise<string | NonSharedBuffer>;
|
|
81
|
-
mkdtemp(prefix: string, options?: import("fs").ObjectEncodingOptions | BufferEncoding | null): Promise<string>;
|
|
82
|
-
mkdtemp(prefix: string, options: import("fs").BufferEncodingOption): Promise<NonSharedBuffer>;
|
|
83
|
-
mkdtemp(prefix: string, options?: import("fs").ObjectEncodingOptions | BufferEncoding | null): Promise<string | NonSharedBuffer>;
|
|
84
|
-
writeFile(file: import("fs").PathLike | nodeFs.FileHandle, data: string | NodeJS.ArrayBufferView | Iterable<string | NodeJS.ArrayBufferView> | AsyncIterable<string | NodeJS.ArrayBufferView>, options?: (import("fs").ObjectEncodingOptions & {
|
|
85
|
-
mode?: import("fs").Mode | undefined;
|
|
86
|
-
flag?: import("fs").OpenMode | undefined;
|
|
68
|
+
}): Promise<import("node:fs").BigIntStatsFs>;
|
|
69
|
+
statfs(path: import("node:fs").PathLike, opts?: import("node:fs").StatFsOptions): Promise<import("node:fs").StatsFs | import("node:fs").BigIntStatsFs>;
|
|
70
|
+
link(existingPath: import("node:fs").PathLike, newPath: import("node:fs").PathLike): Promise<void>;
|
|
71
|
+
unlink(path: import("node:fs").PathLike): Promise<void>;
|
|
72
|
+
chmod(path: import("node:fs").PathLike, mode: import("node:fs").Mode): Promise<void>;
|
|
73
|
+
lchmod(path: import("node:fs").PathLike, mode: import("node:fs").Mode): Promise<void>;
|
|
74
|
+
lchown(path: import("node:fs").PathLike, uid: number, gid: number): Promise<void>;
|
|
75
|
+
lutimes(path: import("node:fs").PathLike, atime: import("node:fs").TimeLike, mtime: import("node:fs").TimeLike): Promise<void>;
|
|
76
|
+
chown(path: import("node:fs").PathLike, uid: number, gid: number): Promise<void>;
|
|
77
|
+
utimes(path: import("node:fs").PathLike, atime: import("node:fs").TimeLike, mtime: import("node:fs").TimeLike): Promise<void>;
|
|
78
|
+
realpath(path: import("node:fs").PathLike, options?: import("node:fs").ObjectEncodingOptions | BufferEncoding | null): Promise<string>;
|
|
79
|
+
realpath(path: import("node:fs").PathLike, options: import("node:fs").BufferEncodingOption): Promise<NonSharedBuffer>;
|
|
80
|
+
realpath(path: import("node:fs").PathLike, options?: import("node:fs").ObjectEncodingOptions | BufferEncoding | null): Promise<string | NonSharedBuffer>;
|
|
81
|
+
mkdtemp(prefix: string, options?: import("node:fs").ObjectEncodingOptions | BufferEncoding | null): Promise<string>;
|
|
82
|
+
mkdtemp(prefix: string, options: import("node:fs").BufferEncodingOption): Promise<NonSharedBuffer>;
|
|
83
|
+
mkdtemp(prefix: string, options?: import("node:fs").ObjectEncodingOptions | BufferEncoding | null): Promise<string | NonSharedBuffer>;
|
|
84
|
+
writeFile(file: import("node:fs").PathLike | nodeFs.FileHandle, data: string | NodeJS.ArrayBufferView | Iterable<string | NodeJS.ArrayBufferView> | AsyncIterable<string | NodeJS.ArrayBufferView>, options?: (import("node:fs").ObjectEncodingOptions & {
|
|
85
|
+
mode?: import("node:fs").Mode | undefined;
|
|
86
|
+
flag?: import("node:fs").OpenMode | undefined;
|
|
87
87
|
flush?: boolean | undefined;
|
|
88
88
|
} & import("events").Abortable) | BufferEncoding | null): Promise<void>;
|
|
89
|
-
appendFile(path: import("fs").PathLike | nodeFs.FileHandle, data: string | NodeJS.ArrayBufferView | Iterable<string | NodeJS.ArrayBufferView> | AsyncIterable<string | NodeJS.ArrayBufferView>, options?: (import("fs").ObjectEncodingOptions & nodeFs.FlagAndOpenMode & {
|
|
89
|
+
appendFile(path: import("node:fs").PathLike | nodeFs.FileHandle, data: string | NodeJS.ArrayBufferView | Iterable<string | NodeJS.ArrayBufferView> | AsyncIterable<string | NodeJS.ArrayBufferView>, options?: (import("node:fs").ObjectEncodingOptions & nodeFs.FlagAndOpenMode & {
|
|
90
90
|
flush?: boolean | undefined;
|
|
91
91
|
}) | BufferEncoding | null): Promise<void>;
|
|
92
|
-
readFile(path: import("fs").PathLike | nodeFs.FileHandle, options?: ({
|
|
92
|
+
readFile(path: import("node:fs").PathLike | nodeFs.FileHandle, options?: ({
|
|
93
93
|
encoding?: null | undefined;
|
|
94
|
-
flag?: import("fs").OpenMode | undefined;
|
|
94
|
+
flag?: import("node:fs").OpenMode | undefined;
|
|
95
95
|
} & import("events").Abortable) | null): Promise<NonSharedBuffer>;
|
|
96
|
-
readFile(path: import("fs").PathLike | nodeFs.FileHandle, options: ({
|
|
96
|
+
readFile(path: import("node:fs").PathLike | nodeFs.FileHandle, options: ({
|
|
97
97
|
encoding: BufferEncoding;
|
|
98
|
-
flag?: import("fs").OpenMode | undefined;
|
|
98
|
+
flag?: import("node:fs").OpenMode | undefined;
|
|
99
99
|
} & import("events").Abortable) | BufferEncoding): Promise<string>;
|
|
100
|
-
readFile(path: import("fs").PathLike | nodeFs.FileHandle, options?: (import("fs").ObjectEncodingOptions & import("events").Abortable & {
|
|
101
|
-
flag?: import("fs").OpenMode | undefined;
|
|
100
|
+
readFile(path: import("node:fs").PathLike | nodeFs.FileHandle, options?: (import("node:fs").ObjectEncodingOptions & import("events").Abortable & {
|
|
101
|
+
flag?: import("node:fs").OpenMode | undefined;
|
|
102
102
|
}) | BufferEncoding | null): Promise<string | NonSharedBuffer>;
|
|
103
|
-
opendir(path: import("fs").PathLike, options?: import("fs").OpenDirOptions): Promise<import("fs").Dir>;
|
|
104
|
-
watch(filename: import("fs").PathLike, options?: nodeFs.WatchOptionsWithStringEncoding | BufferEncoding): NodeJS.AsyncIterator<nodeFs.FileChangeInfo<string>>;
|
|
105
|
-
watch(filename: import("fs").PathLike, options: nodeFs.WatchOptionsWithBufferEncoding | "buffer"): NodeJS.AsyncIterator<nodeFs.FileChangeInfo<NonSharedBuffer>>;
|
|
106
|
-
watch(filename: import("fs").PathLike, options: nodeFs.WatchOptions | BufferEncoding | "buffer"): NodeJS.AsyncIterator<nodeFs.FileChangeInfo<string | NonSharedBuffer>>;
|
|
107
|
-
cp(source: string | URL, destination: string | URL, opts?: import("fs").CopyOptions): Promise<void>;
|
|
103
|
+
opendir(path: import("node:fs").PathLike, options?: import("node:fs").OpenDirOptions): Promise<import("node:fs").Dir>;
|
|
104
|
+
watch(filename: import("node:fs").PathLike, options?: nodeFs.WatchOptionsWithStringEncoding | BufferEncoding): NodeJS.AsyncIterator<nodeFs.FileChangeInfo<string>>;
|
|
105
|
+
watch(filename: import("node:fs").PathLike, options: nodeFs.WatchOptionsWithBufferEncoding | "buffer"): NodeJS.AsyncIterator<nodeFs.FileChangeInfo<NonSharedBuffer>>;
|
|
106
|
+
watch(filename: import("node:fs").PathLike, options: nodeFs.WatchOptions | BufferEncoding | "buffer"): NodeJS.AsyncIterator<nodeFs.FileChangeInfo<string | NonSharedBuffer>>;
|
|
107
|
+
cp(source: string | URL, destination: string | URL, opts?: import("node:fs").CopyOptions): Promise<void>;
|
|
108
108
|
glob(pattern: string | readonly string[]): NodeJS.AsyncIterator<string>;
|
|
109
|
-
glob(pattern: string | readonly string[], options: import("fs").GlobOptionsWithFileTypes): NodeJS.AsyncIterator<import("fs").Dirent>;
|
|
110
|
-
glob(pattern: string | readonly string[], options: import("fs").GlobOptionsWithoutFileTypes): NodeJS.AsyncIterator<string>;
|
|
111
|
-
glob(pattern: string | readonly string[], options: import("fs").GlobOptions): NodeJS.AsyncIterator<import("fs").Dirent | string>;
|
|
112
|
-
constants: typeof import("fs").constants;
|
|
109
|
+
glob(pattern: string | readonly string[], options: import("node:fs").GlobOptionsWithFileTypes): NodeJS.AsyncIterator<import("node:fs").Dirent>;
|
|
110
|
+
glob(pattern: string | readonly string[], options: import("node:fs").GlobOptionsWithoutFileTypes): NodeJS.AsyncIterator<string>;
|
|
111
|
+
glob(pattern: string | readonly string[], options: import("node:fs").GlobOptions): NodeJS.AsyncIterator<import("node:fs").Dirent | string>;
|
|
112
|
+
constants: typeof import("node:fs").constants;
|
|
113
|
+
mkdtempDisposable(prefix: import("node:fs").PathLike, options?: import("node:fs").EncodingOption): Promise<nodeFs.DisposableTempDir>;
|
|
113
114
|
};
|
|
114
115
|
//# sourceMappingURL=fs.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"fs.d.ts","sourceRoot":"","sources":["../../../src/node/utils/fs.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,MAAM,aAAa,CAAA;AAGrC,eAAO,MAAM,EAAE;6BAEkB,MAAM,WAAW,MAAM;iCAWnB,MAAM,WAAW,GAAG;sBAW/B,MAAM,WAAW,GAAG;qBAGrB,MAAM;mBAIR,MAAM;mBAQN,MAAM;;;;;;;;;;;;iBAQ4z1B,CAAC;;;;qBAAqkD,CAAC;iBAA8C,CAAC;;;;qBAAmjB,CAAC;iBAA8C,CAAC;;;qBAAwhB,CAAC;iBAA8C,CAAC;;;;iBAA2hB,CAAC;;;;;iBAA2c,CAAC;;;;;;;cAAu9F,CAAC;;;;;;;cAAoe,CAAC;;;;;;;cAAif,CAAC;;;;;;;;;;;;;;;;;;;;;YAAwqT,CAAC;YAAwC,CAAC;aAAoR,CAAC;;;aAA4/B,CAAC;;;gBAAosE,CAAC;YAAwC,CAAC;;;;YAAqoB,CAAC;;;YAAwrB,CAAC
|
|
1
|
+
{"version":3,"file":"fs.d.ts","sourceRoot":"","sources":["../../../src/node/utils/fs.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,MAAM,aAAa,CAAA;AAGrC,eAAO,MAAM,EAAE;6BAEkB,MAAM,WAAW,MAAM;iCAWnB,MAAM,WAAW,GAAG;sBAW/B,MAAM,WAAW,GAAG;qBAGrB,MAAM;mBAIR,MAAM;mBAQN,MAAM;;;;;;;;;;;;iBAQ4z1B,CAAC;;;;qBAAqkD,CAAC;iBAA8C,CAAC;;;;qBAAmjB,CAAC;iBAA8C,CAAC;;;qBAAwhB,CAAC;iBAA8C,CAAC;;;;iBAA2hB,CAAC;;;;;iBAA2c,CAAC;;;;;;;cAAu9F,CAAC;;;;;;;cAAoe,CAAC;;;;;;;cAAif,CAAC;;;;;;;;;;;;;;;;;;;;;YAAwqT,CAAC;YAAwC,CAAC;aAAoR,CAAC;;;aAA4/B,CAAC;;;gBAAosE,CAAC;YAAwC,CAAC;;;;YAAqoB,CAAC;;;YAAwrB,CAAC;;;;;;;;;;;;;CADjiiD,CAAA"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "eddev",
|
|
3
|
-
"version": "2.
|
|
3
|
+
"version": "2.4.0-beta.1",
|
|
4
4
|
"description": "",
|
|
5
5
|
"main": "index.js",
|
|
6
6
|
"type": "module",
|
|
@@ -68,9 +68,6 @@
|
|
|
68
68
|
"./_internal/ssr-root.js": {
|
|
69
69
|
"import": "./dist/app/entry/ssr-root.js"
|
|
70
70
|
},
|
|
71
|
-
"./_internal/create-vinxi-app.js": {
|
|
72
|
-
"import": "./dist/node/compiler/vinxi-app.js"
|
|
73
|
-
},
|
|
74
71
|
"./_internal": {
|
|
75
72
|
"import": "./dist/app/lib/internal/index.js"
|
|
76
73
|
},
|
|
@@ -80,12 +77,13 @@
|
|
|
80
77
|
},
|
|
81
78
|
"scripts": {
|
|
82
79
|
"dev": "rm -rf dist && node scripts/update-version.js && (tsc -w --project tsconfig.app.json & tsc -w --project tsconfig.node.json)",
|
|
83
|
-
"build": "rm -rf dist && node scripts/update-version.js && tsc"
|
|
80
|
+
"build": "rm -rf dist && node scripts/update-version.js && tsc -p tsconfig.app.json && tsc -p tsconfig.node.json",
|
|
81
|
+
"prepublish": "node scripts/update-version.js",
|
|
82
|
+
"test": "vitest run"
|
|
84
83
|
},
|
|
85
84
|
"author": "",
|
|
86
85
|
"license": "ISC",
|
|
87
86
|
"dependencies": {
|
|
88
|
-
"@babel/types": "^7.25.2",
|
|
89
87
|
"@epic-web/cachified": "^5.2.0",
|
|
90
88
|
"@graphql-codegen/core": "^4.0.0",
|
|
91
89
|
"@graphql-codegen/typescript": "^4.1.6",
|
|
@@ -101,14 +99,13 @@
|
|
|
101
99
|
"@types/react": "^18",
|
|
102
100
|
"@types/react-dom": "^18",
|
|
103
101
|
"@vercel/functions": "^3.5.0",
|
|
104
|
-
"@
|
|
105
|
-
"@vinxi/react": "^0.2.5",
|
|
106
|
-
"@vitejs/plugin-react": "4.3.4",
|
|
102
|
+
"@vitejs/plugin-react": "^6.1.1",
|
|
107
103
|
"chalk": "^5.3.0",
|
|
108
104
|
"change-case-all": "^2.1.0",
|
|
109
105
|
"chokidar": "^3.5.3",
|
|
110
106
|
"commander": "^13.1.0",
|
|
111
107
|
"content-security-policy-builder": "^2.2.0",
|
|
108
|
+
"cookie-es": "^3.1.1",
|
|
112
109
|
"csstype": "^3.1.3",
|
|
113
110
|
"dotenv": "^16.3.1",
|
|
114
111
|
"execa": "^9.5.2",
|
|
@@ -119,13 +116,15 @@
|
|
|
119
116
|
"its-fine": "^2.0.0",
|
|
120
117
|
"linkedom": "^0.18.9",
|
|
121
118
|
"lru-cache": "11.0.2",
|
|
119
|
+
"magic-string": "^1.4.2",
|
|
122
120
|
"mkcert": "^3.2.0",
|
|
121
|
+
"nitro": "3.0.260903-beta",
|
|
123
122
|
"obj-console": "^1.0.2",
|
|
124
123
|
"object-code": "^1.3.3",
|
|
125
124
|
"qs": "^6.13.0",
|
|
126
125
|
"react-compiler-runtime": "^1.0.0",
|
|
127
126
|
"react-inspector": "^9.0.0",
|
|
128
|
-
"rollup-plugin-visualizer": "^
|
|
127
|
+
"rollup-plugin-visualizer": "^7.1.1",
|
|
129
128
|
"sharp-ico": "^0.1.5",
|
|
130
129
|
"superjson": "^2.2.2",
|
|
131
130
|
"ts-poet": "^6.6.0",
|
|
@@ -133,9 +132,8 @@
|
|
|
133
132
|
"undent": "^0.1.0",
|
|
134
133
|
"undici": "6.21.0",
|
|
135
134
|
"valtio": "^2.3.1",
|
|
136
|
-
"
|
|
135
|
+
"vite": "^8.3.2",
|
|
137
136
|
"vite-plugin-glsl": "^1.5.5",
|
|
138
|
-
"vite-tsconfig-paths": "4.3.2",
|
|
139
137
|
"zod": "^4.1.12"
|
|
140
138
|
},
|
|
141
139
|
"devDependencies": {
|
|
@@ -143,7 +141,8 @@
|
|
|
143
141
|
"@types/react": "^18",
|
|
144
142
|
"@types/react-dom": "^18",
|
|
145
143
|
"@types/react-inspector": "^6.0.1",
|
|
146
|
-
"typescript": "^5.5.2"
|
|
144
|
+
"typescript": "^5.5.2",
|
|
145
|
+
"vitest": "^5.0.3"
|
|
147
146
|
},
|
|
148
147
|
"peerDependencies": {
|
|
149
148
|
"react": "^18.3.1",
|
|
@@ -52,12 +52,13 @@ Fast mode runs:
|
|
|
52
52
|
|
|
53
53
|
The full `eddev dev` command runs every mode:
|
|
54
54
|
|
|
55
|
-
| Mode | What It Does
|
|
56
|
-
| ------------ |
|
|
57
|
-
| `serverless` | Starts the local serverless dev server on port `8080`.
|
|
58
|
-
| `graphql` | Runs GraphQL codegen and optimized query output.
|
|
59
|
-
| `
|
|
60
|
-
|
|
55
|
+
| Mode | What It Does |
|
|
56
|
+
| ------------ | ------------------------------------------------------------------------------------------------------------- |
|
|
57
|
+
| `serverless` | Starts the local serverless dev server on port `8080`. |
|
|
58
|
+
| `graphql` | Runs GraphQL codegen and optimized query output. |
|
|
59
|
+
| `spa` | Builds and watches the WordPress-hosted SPA bundles (frontend and admin/editor), shown as **SPA Client**. |
|
|
60
|
+
|
|
61
|
+
`frontend` and `admin` are still accepted as modes, and build just one of the two SPA bundles.
|
|
61
62
|
|
|
62
63
|
Use the full command when you specifically need the local WordPress frontend or admin/editor asset bundles. If you are previewing the site through `https://site.local:8080`, fast mode is usually enough.
|
|
63
64
|
|
|
@@ -78,7 +79,7 @@ yarn dev --fast
|
|
|
78
79
|
yarn dev --https false
|
|
79
80
|
```
|
|
80
81
|
|
|
81
|
-
`--mode <modes>` is available for debugging individual services, for example `yarn dev --mode graphql` or `yarn dev --mode
|
|
82
|
+
`--mode <modes>` is available for debugging individual services, for example `yarn dev --mode graphql` or `yarn dev --mode spa`. Prefer `--fast` for normal project work.
|
|
82
83
|
|
|
83
84
|
When HTTPS is enabled, eddev creates a local certificate under `.eddev/certs/`. If macOS does not trust the certificate yet, the CLI prints Keychain instructions.
|
|
84
85
|
|
|
@@ -98,6 +99,7 @@ The CLI writes several generated files during `dev` and `build`.
|
|
|
98
99
|
| `schema.json` | WordPress GraphQL schema | Local schema file for editor tooling. |
|
|
99
100
|
| `.eddev/queries/**` | Project GraphQL files | Optimized query text and fragments used by the PHP runtime. |
|
|
100
101
|
| `.eddev/dev*` and `.eddev/prod*` | Build codegen | Internal bootstrap files for SPA and serverless builds. |
|
|
102
|
+
| `.eddev/output/`, `.eddev/nitro/` | `eddev build --serverless` (Node preset) | The local serverless build, run by `eddev preview`. Vercel builds go to `.vercel/output/` instead. |
|
|
101
103
|
|
|
102
104
|
Do not edit generated files directly. Change the source block, view, route, or GraphQL file instead.
|
|
103
105
|
|
|
@@ -152,7 +154,7 @@ See [Serverless](/docs/serverless) for Vercel setup, `SITE_URL`, `SITE_API_KEY`,
|
|
|
152
154
|
|
|
153
155
|
## `eddev preview` [#eddev-preview]
|
|
154
156
|
|
|
155
|
-
`eddev preview` runs the local production serverless build from `.output/server/index.mjs`. It is mainly useful after `eddev build --serverless
|
|
157
|
+
`eddev preview` runs the local production serverless build from `.eddev/output/server/index.mjs`. It is mainly useful after `eddev build --serverless`, which builds for Node (the `node-server` preset) when run outside Vercel. Set `TARGET` (eg. `TARGET=cloudflare-module`) to build for another platform.
|
|
156
158
|
|
|
157
159
|
```bash
|
|
158
160
|
eddev preview
|
package/tsconfig.node.json
CHANGED
|
@@ -1,7 +1,9 @@
|
|
|
1
1
|
{
|
|
2
2
|
"compilerOptions": {
|
|
3
3
|
"target": "ESNext",
|
|
4
|
-
"lib": [
|
|
4
|
+
"lib": [
|
|
5
|
+
"ESNext"
|
|
6
|
+
],
|
|
5
7
|
"jsx": "react-jsx",
|
|
6
8
|
"module": "NodeNext",
|
|
7
9
|
"moduleResolution": "NodeNext",
|
|
@@ -14,11 +16,21 @@
|
|
|
14
16
|
"forceConsistentCasingInFileNames": true,
|
|
15
17
|
"strict": true,
|
|
16
18
|
"skipLibCheck": true,
|
|
17
|
-
"types": [
|
|
19
|
+
"types": [
|
|
20
|
+
"./types.node.d.ts"
|
|
21
|
+
],
|
|
18
22
|
"paths": {
|
|
19
|
-
"@wordpress/*": [
|
|
23
|
+
"@wordpress/*": [
|
|
24
|
+
"./wp/@types/*"
|
|
25
|
+
]
|
|
20
26
|
}
|
|
21
27
|
},
|
|
22
|
-
"include": [
|
|
23
|
-
|
|
28
|
+
"include": [
|
|
29
|
+
"src/node",
|
|
30
|
+
"types.node.d.ts"
|
|
31
|
+
],
|
|
32
|
+
"exclude": [
|
|
33
|
+
"src/app",
|
|
34
|
+
"src/**/*.test.ts"
|
|
35
|
+
]
|
|
24
36
|
}
|
package/types.env.d.ts
CHANGED
|
@@ -15,7 +15,7 @@ declare global {
|
|
|
15
15
|
client: boolean
|
|
16
16
|
|
|
17
17
|
/**
|
|
18
|
-
* Whether this bundle belongs to the
|
|
18
|
+
* Whether this bundle belongs to the serverless/SSR application.
|
|
19
19
|
*
|
|
20
20
|
* This is also `true` when running the local serverless dev server; it does
|
|
21
21
|
* not specifically mean that the code is deployed on Vercel.
|
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
import { Project } from "../project/project.js";
|
|
2
|
-
import { StatefulLog } from "../utils/stateful-log.js";
|
|
3
|
-
type Options = {
|
|
4
|
-
project: Project;
|
|
5
|
-
console: StatefulLog<any>;
|
|
6
|
-
};
|
|
7
|
-
export declare function buildVinxi(opts: Options): Promise<void>;
|
|
8
|
-
export {};
|
|
9
|
-
//# sourceMappingURL=build-vinxi.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"build-vinxi.d.ts","sourceRoot":"","sources":["../../../src/node/compiler/build-vinxi.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,OAAO,EAAE,MAAM,uBAAuB,CAAA;AAC/C,OAAO,EAAE,WAAW,EAAE,MAAM,0BAA0B,CAAA;AAItD,KAAK,OAAO,GAAG;IACb,OAAO,EAAE,OAAO,CAAA;IAChB,OAAO,EAAE,WAAW,CAAC,GAAG,CAAC,CAAA;CAC1B,CAAA;AAED,wBAAsB,UAAU,CAAC,IAAI,EAAE,OAAO,iBA0C7C"}
|
|
@@ -1,39 +0,0 @@
|
|
|
1
|
-
import { code } from "ts-poet";
|
|
2
|
-
import { createVinxiApp } from "./vinxi-app.js";
|
|
3
|
-
import { createVinxiCodegen } from "./vinxi-codegen.js";
|
|
4
|
-
export async function buildVinxi(opts) {
|
|
5
|
-
const { project, console } = opts;
|
|
6
|
-
const preset = process.env.TARGET ??
|
|
7
|
-
process.env.PRESET ??
|
|
8
|
-
process.env.SERVER_PRESET ??
|
|
9
|
-
process.env.SERVER_TARGET ??
|
|
10
|
-
process.env.NITRO_PRESET ??
|
|
11
|
-
process.env.NITRO_TARGET ??
|
|
12
|
-
(process.env.VERCEL ? "vercel" : undefined) ??
|
|
13
|
-
(process.versions.bun !== undefined ? "bun" : "node-server");
|
|
14
|
-
const appConf = {
|
|
15
|
-
mode: "production",
|
|
16
|
-
origin: project.origin,
|
|
17
|
-
publicUrl: project.publicUrl,
|
|
18
|
-
rootDir: project.rootDir,
|
|
19
|
-
rpcBases: (await project.serverRoutes.get()).bases,
|
|
20
|
-
preset,
|
|
21
|
-
config: project.config,
|
|
22
|
-
};
|
|
23
|
-
console.log("Building vinxi app with preset:", preset);
|
|
24
|
-
const codegen = createVinxiCodegen({
|
|
25
|
-
mode: "production",
|
|
26
|
-
project: project,
|
|
27
|
-
serverless: true,
|
|
28
|
-
});
|
|
29
|
-
codegen.registerFile({
|
|
30
|
-
name: "../../app.config.mjs",
|
|
31
|
-
generate: code /* ts */ `
|
|
32
|
-
import { createVinxiApp } from 'eddev/_internal/create-vinxi-app.js'
|
|
33
|
-
export default createVinxiApp(${JSON.stringify(appConf)})
|
|
34
|
-
`,
|
|
35
|
-
});
|
|
36
|
-
await codegen.runAndWatch();
|
|
37
|
-
const app = createVinxiApp(appConf);
|
|
38
|
-
await app.build();
|
|
39
|
-
}
|
|
@@ -1,14 +0,0 @@
|
|
|
1
|
-
import { Project } from "../project/project.js";
|
|
2
|
-
export declare const adminLog: import("../utils/stateful-log.js").StatefulLog<unknown>;
|
|
3
|
-
type Options = {
|
|
4
|
-
mode: "development" | "production";
|
|
5
|
-
watch?: boolean;
|
|
6
|
-
};
|
|
7
|
-
export declare class AdminBundler {
|
|
8
|
-
project: Project;
|
|
9
|
-
opts: Options;
|
|
10
|
-
constructor(project: Project, opts: Options);
|
|
11
|
-
start(): Promise<void>;
|
|
12
|
-
}
|
|
13
|
-
export {};
|
|
14
|
-
//# sourceMappingURL=bundler.admin.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"bundler.admin.d.ts","sourceRoot":"","sources":["../../../src/node/compiler/bundler.admin.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,OAAO,EAAE,MAAM,uBAAuB,CAAA;AAO/C,eAAO,MAAM,QAAQ,yDAAU,CAAA;AAE/B,KAAK,OAAO,GAAG;IACb,IAAI,EAAE,aAAa,GAAG,YAAY,CAAA;IAClC,KAAK,CAAC,EAAE,OAAO,CAAA;CAChB,CAAA;AAED,qBAAa,YAAY;IAEd,OAAO,EAAE,OAAO;IAChB,IAAI,EAAE,OAAO;gBADb,OAAO,EAAE,OAAO,EAChB,IAAI,EAAE,OAAO;IAGhB,KAAK;CA+BZ"}
|
|
@@ -1,37 +0,0 @@
|
|
|
1
|
-
import { relative } from "path";
|
|
2
|
-
import { build, defineConfig, mergeConfig } from "vite";
|
|
3
|
-
import { createConsole } from "../utils/stateful-log.js";
|
|
4
|
-
import { getViteConfig } from "./get-vite-config.js";
|
|
5
|
-
const console = createConsole("Admin Bundle", "admin");
|
|
6
|
-
export const adminLog = console;
|
|
7
|
-
export class AdminBundler {
|
|
8
|
-
project;
|
|
9
|
-
opts;
|
|
10
|
-
constructor(project, opts) {
|
|
11
|
-
this.project = project;
|
|
12
|
-
this.opts = opts;
|
|
13
|
-
}
|
|
14
|
-
async start() {
|
|
15
|
-
console.info(`Creating ${this.opts.mode} WordPress admin build...`);
|
|
16
|
-
const baseConfig = getViteConfig({
|
|
17
|
-
console,
|
|
18
|
-
mode: this.opts.mode,
|
|
19
|
-
publicUrl: this.project.publicUrl,
|
|
20
|
-
rootDir: this.project.rootDir,
|
|
21
|
-
outDir: relative(this.project.rootDir, "./dist/cms/"),
|
|
22
|
-
serverless: false,
|
|
23
|
-
target: "cms",
|
|
24
|
-
client: true,
|
|
25
|
-
});
|
|
26
|
-
console.verbose("Vite config:", baseConfig);
|
|
27
|
-
await build(mergeConfig(baseConfig, defineConfig({
|
|
28
|
-
build: {
|
|
29
|
-
watch: this.opts.watch
|
|
30
|
-
? {
|
|
31
|
-
buildDelay: 200,
|
|
32
|
-
}
|
|
33
|
-
: undefined,
|
|
34
|
-
},
|
|
35
|
-
})));
|
|
36
|
-
}
|
|
37
|
-
}
|
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
import { Project } from "../project/project.js";
|
|
2
|
-
export declare const frontendLog: import("../utils/stateful-log.js").StatefulLog<unknown>;
|
|
3
|
-
type Options = {
|
|
4
|
-
mode: "development" | "production";
|
|
5
|
-
watch?: boolean;
|
|
6
|
-
bundleAnalysis?: boolean;
|
|
7
|
-
};
|
|
8
|
-
export declare class FrontendBundler {
|
|
9
|
-
project: Project;
|
|
10
|
-
opts: Options;
|
|
11
|
-
constructor(project: Project, opts: Options);
|
|
12
|
-
start(): Promise<void>;
|
|
13
|
-
}
|
|
14
|
-
export {};
|
|
15
|
-
//# sourceMappingURL=bundler.frontend.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"bundler.frontend.d.ts","sourceRoot":"","sources":["../../../src/node/compiler/bundler.frontend.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,OAAO,EAAE,MAAM,uBAAuB,CAAA;AAQ/C,eAAO,MAAM,WAAW,yDAAU,CAAA;AAElC,KAAK,OAAO,GAAG;IACb,IAAI,EAAE,aAAa,GAAG,YAAY,CAAA;IAClC,KAAK,CAAC,EAAE,OAAO,CAAA;IACf,cAAc,CAAC,EAAE,OAAO,CAAA;CACzB,CAAA;AAED,qBAAa,eAAe;IAEjB,OAAO,EAAE,OAAO;IAChB,IAAI,EAAE,OAAO;gBADb,OAAO,EAAE,OAAO,EAChB,IAAI,EAAE,OAAO;IAGhB,KAAK;CAwCZ"}
|