miniflare
Advanced tools
Comparing version
@@ -7,2 +7,9 @@ // src/workers/assets/rpc-proxy.worker.ts | ||
} | ||
constructor(ctx, env) { | ||
return super(ctx, env), new Proxy(this, { | ||
get(target, prop) { | ||
return Reflect.has(target, prop) ? Reflect.get(target, prop) : Reflect.get(target.env.USER_WORKER, prop); | ||
} | ||
}); | ||
} | ||
}; | ||
@@ -9,0 +16,0 @@ export { |
@@ -863,3 +863,5 @@ // ../../node_modules/.pnpm/kleur@4.1.5/node_modules/kleur/colors.mjs | ||
} | ||
if (request = new Request(url, request), request.headers.set("Accept-Encoding", "br, gzip"), rewriteHeadersFromOriginalUrl && request.headers.set("Host", url.host), clientIp && !request.headers.get("CF-Connecting-IP")) { | ||
request = new Request(url, request), request.headers.set("Accept-Encoding", "br, gzip"); | ||
let secFetchMode = request.headers.get("X-Mf-Sec-Fetch-Mode"); | ||
if (secFetchMode && request.headers.set("Sec-Fetch-Mode", secFetchMode), request.headers.delete("X-Mf-Sec-Fetch-Mode"), rewriteHeadersFromOriginalUrl && request.headers.set("Host", url.host), clientIp && !request.headers.get("CF-Connecting-IP")) { | ||
let ipv4Regex = /(?<ip>.*?):\d+/, ipv6Regex = /\[(?<ip>.*?)\]:\d+/, ip = clientIp.match(ipv6Regex)?.groups?.ip ?? clientIp.match(ipv4Regex)?.groups?.ip; | ||
@@ -866,0 +868,0 @@ ip && request.headers.set("CF-Connecting-IP", ip); |
{ | ||
"name": "miniflare", | ||
"version": "0.0.0-5d34c8f5d", | ||
"version": "0.0.0-5d78760af", | ||
"description": "Fun, full-featured, fully-local simulator for Cloudflare Workers", | ||
@@ -40,3 +40,3 @@ "keywords": [ | ||
"undici": "^5.28.5", | ||
"workerd": "1.20250310.0", | ||
"workerd": "1.20250319.0", | ||
"ws": "8.18.0", | ||
@@ -48,3 +48,3 @@ "youch": "3.2.3", | ||
"@ava/typescript": "^4.1.0", | ||
"@cloudflare/workers-types": "^4.20250310.0", | ||
"@cloudflare/workers-types": "^4.20250319.0", | ||
"@microsoft/api-extractor": "7.49.1", | ||
@@ -73,2 +73,3 @@ "@types/debug": "^4.1.7", | ||
"expect-type": "^0.15.0", | ||
"get-port": "^7.1.0", | ||
"heap-js": "^2.5.0", | ||
@@ -83,5 +84,5 @@ "http-cache-semantics": "^4.1.0", | ||
"which": "^2.0.2", | ||
"@cloudflare/workflows-shared": "0.3.0", | ||
"@cloudflare/kv-asset-handler": "0.4.0", | ||
"@cloudflare/workflows-shared": "0.3.0", | ||
"@cloudflare/workers-shared": "0.0.0-5d34c8f5d" | ||
"@cloudflare/workers-shared": "0.0.0-5d78760af" | ||
}, | ||
@@ -88,0 +89,0 @@ "engines": { |
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is not supported yet
2948684
1.04%46782
1.1%38
2.7%9
12.5%+ Added
+ Added
+ Added
+ Added
+ Added
+ Added
- Removed
- Removed
- Removed
- Removed
- Removed
- Removed
Updated