@builder.io/dev-tools 1.6.48 → 1.6.49-dev.202505181635.974b7467
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/angular/index.cjs +46 -1
- package/angular/index.mjs +21 -1
- package/cli/index.cjs +105763 -3569
- package/cli/index.cjs.map +4 -4
- package/core/index.cjs +13656 -851
- package/core/index.mjs +13647 -852
- package/figma/index.cjs +39 -1
- package/figma/index.mjs +19 -1
- package/node/index.cjs +25304 -105
- package/node/index.mjs +25308 -105
- package/package.json +1 -1
- package/remix/build.cjs +132 -1
- package/remix/index.mjs +113 -1
- package/server/index.cjs +15015 -1362
- package/server/index.mjs +15008 -1362
- package/types/cli/code-server.d.ts +0 -0
- package/types/cli/codegen.d.ts +2 -1
- package/types/cli/io-service.d.ts +86 -0
- package/types/cli/launch.d.ts +6 -2
- package/types/core/adapters/vite/ensure-remix-config.d.ts +6 -0
- package/types/core/adapters/vite/remix-utils.d.ts +10 -0
- package/types/core/adapters/vite/vite-config-helpers.d.ts +6 -0
- package/types/tsconfig.tsbuildinfo +1 -1
- package/vite/index.cjs +153 -3
- package/vite/index.mjs +119 -3
- package/webpack/index.cjs +2883 -27
- package/webpack/index.mjs +2871 -27
|
File without changes
|
package/types/cli/codegen.d.ts
CHANGED
|
@@ -75,7 +75,7 @@ export declare class CodeGenSession {
|
|
|
75
75
|
error: string;
|
|
76
76
|
details: string;
|
|
77
77
|
}>;
|
|
78
|
-
createPR(repoFullName: string, githubToken: string, branchName: string): Promise<{
|
|
78
|
+
createPR(repoFullName: string, githubToken: string, branchName: string, projectId: string): Promise<{
|
|
79
79
|
success: boolean;
|
|
80
80
|
prUrl: any;
|
|
81
81
|
prNumber: any;
|
|
@@ -88,6 +88,7 @@ export declare class CodeGenSession {
|
|
|
88
88
|
prUrl?: undefined;
|
|
89
89
|
prNumber?: undefined;
|
|
90
90
|
}>;
|
|
91
|
+
getCommitMode(): CommitMode | undefined;
|
|
91
92
|
setCommitMode(commitMode: CommitMode): void;
|
|
92
93
|
pushChanges(pullFirst?: boolean): Promise<void>;
|
|
93
94
|
hasChangesRelativeToRemote(): Promise<boolean>;
|
|
@@ -0,0 +1,86 @@
|
|
|
1
|
+
import { type SelectOptions, type ConfirmOptions, type TextOptions } from "@clack/prompts";
|
|
2
|
+
import { spinner } from "./spinner";
|
|
3
|
+
import type { WebSocket } from "ws";
|
|
4
|
+
export interface IOService {
|
|
5
|
+
log(str: string): void;
|
|
6
|
+
info(str: string): void;
|
|
7
|
+
warn(str: string): void;
|
|
8
|
+
error(str: string): void;
|
|
9
|
+
write(text: string): void;
|
|
10
|
+
writeMetadata(metadata: Record<string, any>): void;
|
|
11
|
+
confirm(options: ConfirmOptions): Promise<boolean | symbol>;
|
|
12
|
+
text(options: TextOptions): Promise<string | symbol>;
|
|
13
|
+
select<Value>(options: SelectOptions<Value>): Promise<Value | symbol>;
|
|
14
|
+
createSpinner(): ReturnType<typeof spinner>;
|
|
15
|
+
isInteractive(): boolean;
|
|
16
|
+
isTTY(): boolean;
|
|
17
|
+
exit(code: number): Promise<void>;
|
|
18
|
+
}
|
|
19
|
+
export declare class ConsoleIOService implements IOService {
|
|
20
|
+
log(str: string): void;
|
|
21
|
+
info(str: string): void;
|
|
22
|
+
warn(str: string): void;
|
|
23
|
+
error(str: string): void;
|
|
24
|
+
write(text: string): void;
|
|
25
|
+
writeMetadata(_: Record<string, any>): void;
|
|
26
|
+
confirm(options: ConfirmOptions): Promise<boolean | symbol>;
|
|
27
|
+
text(options: TextOptions): Promise<string | symbol>;
|
|
28
|
+
select<Value>(options: SelectOptions<Value>): Promise<Value | symbol>;
|
|
29
|
+
createSpinner(): ReturnType<typeof spinner>;
|
|
30
|
+
isInteractive(): boolean;
|
|
31
|
+
isTTY(): boolean;
|
|
32
|
+
exit(code: number): Promise<void>;
|
|
33
|
+
}
|
|
34
|
+
export interface BaseMessage {
|
|
35
|
+
type: string;
|
|
36
|
+
[key: string]: any;
|
|
37
|
+
}
|
|
38
|
+
export interface LogMessage extends BaseMessage {
|
|
39
|
+
type: "log";
|
|
40
|
+
level: "info" | "warn" | "error";
|
|
41
|
+
message: string;
|
|
42
|
+
}
|
|
43
|
+
export interface WriteMessage extends BaseMessage {
|
|
44
|
+
type: "write";
|
|
45
|
+
text: string;
|
|
46
|
+
}
|
|
47
|
+
export interface SpinnerMessage extends BaseMessage {
|
|
48
|
+
type: "spinner";
|
|
49
|
+
status: "start" | "stop";
|
|
50
|
+
message: string;
|
|
51
|
+
code?: number;
|
|
52
|
+
}
|
|
53
|
+
export interface PromptRequest extends BaseMessage {
|
|
54
|
+
type: "prompt";
|
|
55
|
+
promptType: "text" | "confirm" | "select";
|
|
56
|
+
options: any;
|
|
57
|
+
requestId: string;
|
|
58
|
+
}
|
|
59
|
+
export interface PromptResponse extends BaseMessage {
|
|
60
|
+
type: "prompt_response";
|
|
61
|
+
requestId: string;
|
|
62
|
+
value: any;
|
|
63
|
+
cancelled?: boolean;
|
|
64
|
+
}
|
|
65
|
+
export declare class WebSocketIOService implements IOService {
|
|
66
|
+
private ws;
|
|
67
|
+
private promptCallbacks;
|
|
68
|
+
private messageQueue;
|
|
69
|
+
private isProcessing;
|
|
70
|
+
constructor(ws: WebSocket);
|
|
71
|
+
private sendMessage;
|
|
72
|
+
private prompt;
|
|
73
|
+
log(...args: any[]): void;
|
|
74
|
+
info(...args: any[]): void;
|
|
75
|
+
warn(...args: any[]): void;
|
|
76
|
+
error(...args: any[]): void;
|
|
77
|
+
write(text: string): void;
|
|
78
|
+
writeMetadata(metadata: Record<string, any>): void;
|
|
79
|
+
confirm(options: ConfirmOptions): Promise<boolean | symbol>;
|
|
80
|
+
text(options: TextOptions): Promise<string | symbol>;
|
|
81
|
+
select<Value>(options: SelectOptions<Value>): Promise<Value | symbol>;
|
|
82
|
+
createSpinner(): ReturnType<typeof spinner>;
|
|
83
|
+
isInteractive(): boolean;
|
|
84
|
+
isTTY(): boolean;
|
|
85
|
+
exit(code: number): Promise<void>;
|
|
86
|
+
}
|
package/types/cli/launch.d.ts
CHANGED
|
@@ -6,8 +6,6 @@ import type { CLIArgs } from "./index";
|
|
|
6
6
|
export declare const PROXY_PORT = 48752;
|
|
7
7
|
export interface LaunchArgs extends CLIArgs {
|
|
8
8
|
cwdAgent?: string;
|
|
9
|
-
/** Fusion project ID */
|
|
10
|
-
projectId?: string;
|
|
11
9
|
/** Silent mode for launch command */
|
|
12
10
|
silent?: boolean;
|
|
13
11
|
/** Port number for the dev server */
|
|
@@ -22,6 +20,12 @@ export interface LaunchArgs extends CLIArgs {
|
|
|
22
20
|
dev?: boolean;
|
|
23
21
|
/** Skip browser auto-open (flag form) */
|
|
24
22
|
open?: boolean;
|
|
23
|
+
/**
|
|
24
|
+
* If true, CLI will be interactive and prompt the user for input.
|
|
25
|
+
*
|
|
26
|
+
* @default true
|
|
27
|
+
*/
|
|
28
|
+
interactive?: boolean;
|
|
25
29
|
/**
|
|
26
30
|
* Decides whether to skip authentication for the user's proxy server.
|
|
27
31
|
* Our own _builder.io/ endpoitns are always authenticated.
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import type { DevToolsSys } from "../..";
|
|
2
|
+
import type { EnsureConfigResult } from "../../../types";
|
|
3
|
+
/**
|
|
4
|
+
* Ensure the Remix Vite config has the necessary plugins and settings
|
|
5
|
+
*/
|
|
6
|
+
export declare function ensureRemixConfig(sys: DevToolsSys, configFilePath: string, configContent: string): Promise<EnsureConfigResult>;
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import type { DevToolsSys } from "../..";
|
|
2
|
+
import type ts from "typescript";
|
|
3
|
+
/**
|
|
4
|
+
* Check if the current project is using Remix framework
|
|
5
|
+
*/
|
|
6
|
+
export declare function isRemixFramework(sys: DevToolsSys): boolean;
|
|
7
|
+
/**
|
|
8
|
+
* Update an object literal to include the external dependencies for Remix
|
|
9
|
+
*/
|
|
10
|
+
export declare function updateCommonJsLibrary(sys: DevToolsSys, config: ts.ObjectLiteralExpression): ts.ObjectLiteralExpression | null;
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import type { DevToolsSys } from "../..";
|
|
2
|
+
import type { EnsureConfigResult } from "../../../types";
|
|
3
|
+
/**
|
|
4
|
+
* Update a Vite config file to include a plugin
|
|
5
|
+
*/
|
|
6
|
+
export declare function updateViteConfig(sys: DevToolsSys, configFilePath: string, configContent: string, pluginName: string, importPath: string): Promise<EnsureConfigResult>;
|