You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This enables binding to [named entrypoints](https://developers.cloudflare.com/workers/runtime-apis/bindings/service-bindings/rpc/#named-entrypoints) defined in a `vite dev` session from another `vite dev` or `wrangler dev` session running locally.
// Only connect the tail consumers that represent Workers that are defined in the Vite config. Warn that a tail might be omitted otherwise
97
-
// This _differs from service bindings_ because tail consumers are "optional" in a sense, and shouldn't affect the runtime behaviour of a Worker
98
-
for(consttailServiceoftails??[]){
99
-
letname: string;
100
-
if(typeoftailService==="string"){
101
-
name=tailService;
102
-
}elseif(
103
-
typeoftailService==="object"&&
104
-
"name"intailService&&
105
-
typeoftailService.name==="string"
106
-
){
107
-
name=tailService.name;
108
-
}else{
109
-
// Don't interfere with network-based tail connections (e.g. via the dev registry), or kCurrentWorker
110
-
continue;
111
-
}
112
-
constfound=userWorkers.some((w)=>w.name===name);
113
-
114
-
if(!found){
115
-
log(
116
-
colors.dim(
117
-
colors.yellow(
118
-
`Tail consumer "${name}" was not found in your config. Make sure you add it to the config or run it in another dev session if you'd like to simulate receiving tail events locally.`
119
-
)
120
-
)
121
-
);
122
-
}
123
-
}
124
-
}
125
-
126
90
/** Map that maps worker configPaths to their existing remote proxy session data (if any) */
127
91
constremoteProxySessionsDataMap=newMap<
128
92
string,
@@ -344,15 +308,46 @@ export async function getDevMiniflareOptions(
0 commit comments