Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 11 additions & 0 deletions .changeset/c3-frameworks-update-12717.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
---
"create-cloudflare": patch
---

Update dependencies of "create-cloudflare"

The following dependency versions have been updated:

| Dependency | From | To |
| ------------- | ----- | ----- |
| create-analog | 2.2.3 | 2.3.1 |
11 changes: 11 additions & 0 deletions .changeset/c3-frameworks-update-12718.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
---
"create-cloudflare": patch
---

Update dependencies of "create-cloudflare"

The following dependency versions have been updated:

| Dependency | From | To |
| ---------- | ------ | ------ |
| sv | 0.12.2 | 0.12.4 |
11 changes: 11 additions & 0 deletions .changeset/c3-frameworks-update-12720.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
---
"create-cloudflare": patch
---

Update dependencies of "create-cloudflare"

The following dependency versions have been updated:

| Dependency | From | To |
| ----------- | ---------------------- | ---------------------- |
| create-waku | 0.12.5-1.0.0-alpha.4-0 | 0.12.5-1.0.0-alpha.5-0 |
7 changes: 7 additions & 0 deletions .changeset/polite-schools-buy.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
---
"create-cloudflare": patch
---

Update SolidStart template for compatibility with v2.

SolidStart v2 uses the `nitro` Vite plugin so we now update the Nitro config in `vite.config.ts` rather than `app.config.ts`.
6 changes: 6 additions & 0 deletions .changeset/remove-ai-search-workaround.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
---
"miniflare": patch
"wrangler": patch
---

Remove temporary AI Search RPC workaround (no user-facing changes)
7 changes: 7 additions & 0 deletions .changeset/sharp-sheep-buy.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
---
"wrangler": minor
---

Add type generation support for experimental `secrets` property.

This has precedence over deriving secret types from .env and .dev.vars files.
Original file line number Diff line number Diff line change
Expand Up @@ -813,6 +813,8 @@ function getExperimentalFrameworkTestConfig(
},
{
name: "solid",
// quarantined: SolidStart moved from app.config to vite.config with Nitro plugin
quarantine: true,
promptHandlers: [
{
matcher: /Which template would you like to use/,
Expand Down
6 changes: 3 additions & 3 deletions packages/create-cloudflare/src/frameworks/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
],
"dependencies": {
"create-astro": "4.13.2",
"create-analog": "2.2.3",
"create-analog": "2.3.1",
"@angular/create": "21.1.4",
"create-docusaurus": "3.9.2",
"create-hono": "0.19.4",
Expand All @@ -18,10 +18,10 @@
"create-solid": "0.6.13",
"create-vike": "0.0.581",
"create-vue": "3.21.1",
"create-waku": "0.12.5-1.0.0-alpha.4-0",
"create-waku": "0.12.5-1.0.0-alpha.5-0",
"@tanstack/create-start": "0.59.8",
"gatsby": "5.16.1",
"sv": "0.12.2",
"sv": "0.12.4",
"nuxi": "3.33.1"
}
}
39 changes: 14 additions & 25 deletions packages/create-cloudflare/templates/solid/c3.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
import { logRaw, updateStatus } from "@cloudflare/cli";
import { blue } from "@cloudflare/cli/colors";
import { getLocalWorkerdCompatibilityDate } from "@cloudflare/workers-utils";
import { runFrameworkGenerator } from "frameworks/index";
import { mergeObjectProperties, transformFile } from "helpers/codemod";
import { usesTypescript } from "helpers/files";
Expand All @@ -21,42 +20,32 @@ const generate = async (ctx: C3Context) => {

const configure = async (ctx: C3Context) => {
usesTypescript(ctx);
const filePath = `app.config.${usesTypescript(ctx) ? "ts" : "js"}`;

const { date: compatDate } = getLocalWorkerdCompatibilityDate({
projectPath: ctx.project.path,
});
const filePath = `vite.config.${usesTypescript(ctx) ? "ts" : "js"}`;

updateStatus(`Updating configuration in ${blue(filePath)}`);

transformFile(filePath, {
visitCallExpression: function (n) {
const callee = n.node.callee as recast.types.namedTypes.Identifier;
if (callee.name !== "defineConfig") {
if (callee.name !== "nitro") {
return this.traverse(n);
}

const b = recast.types.builders;
mergeObjectProperties(
n.node.arguments[0] as recast.types.namedTypes.ObjectExpression,
[
b.objectProperty(
b.identifier("server"),
b.objectExpression([
// preset: "cloudflare_module"
b.objectProperty(
b.identifier("preset"),
b.stringLiteral("cloudflare_module"),
),
b.objectProperty(
b.identifier("compatibilityDate"),
b.stringLiteral(compatDate),
),
]),
),
],
const presetProp = b.objectProperty(
b.identifier("preset"),
b.stringLiteral("cloudflare-module"),
);

if (n.node.arguments.length === 0) {
n.node.arguments.push(b.objectExpression([presetProp]));
} else {
mergeObjectProperties(
n.node.arguments[0] as recast.types.namedTypes.ObjectExpression,
[presetProp],
);
}

return false;
},
});
Expand Down
Original file line number Diff line number Diff line change
@@ -1,14 +1,9 @@
{
"name": "<WORKER_NAME>",
"main": "./.output/server/index.mjs",
"compatibility_date": "<COMPATIBILITY_DATE>",
"compatibility_flags": [
"nodejs_compat"
],
"assets": {
"binding": "ASSETS",
"directory": "./.output/public"
},
"observability": {
"enabled": true
}
Expand Down
2 changes: 1 addition & 1 deletion packages/miniflare/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@
"@cspotcode/source-map-support": "0.8.1",
"sharp": "^0.34.5",
"undici": "catalog:default",
"workerd": "1.20260226.1",
"workerd": "1.20260301.1",
"ws": "catalog:default",
"youch": "4.1.0-beta.10"
},
Expand Down
3 changes: 1 addition & 2 deletions packages/miniflare/src/plugins/ai/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -70,8 +70,7 @@ export const AI_PLUGIN: Plugin<typeof AIOptionsSchema> = {
),
worker: remoteProxyClientWorker(
options.ai.remoteProxyConnectionString,
options.ai.binding,
"ai"
options.ai.binding
),
},
];
Expand Down
1 change: 0 additions & 1 deletion packages/miniflare/src/plugins/dispatch-namespace/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,6 @@ export const DISPATCH_NAMESPACE_PLUGIN: Plugin<
worker: remoteProxyClientWorker(
config.remoteProxyConnectionString,
name,
undefined,
SCRIPT_DISPATCH_NAMESPACE_PROXY
),
}));
Expand Down
9 changes: 0 additions & 9 deletions packages/miniflare/src/plugins/shared/constants.ts
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,6 @@ export function objectEntryWorker(
export function remoteProxyClientWorker(
remoteProxyConnectionString: RemoteProxyConnectionString | undefined,
binding: string,
bindingType?: string,
script?: () => string
) {
return {
Expand All @@ -100,14 +99,6 @@ export function remoteProxyClientWorker(
name: "binding",
text: binding,
},
...(bindingType
? [
{
name: "bindingType",
text: bindingType,
},
]
: []),
],
};
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,12 +6,10 @@ import { newWebSocketRpcSession } from "capnweb";
export type RemoteBindingEnv = {
remoteProxyConnectionString?: string;
binding: string;
bindingType?: string;
};

/** Headers sent alongside proxy requests to provide additional context. */
export type ProxyMetadata = {
"MF-Binding-Type"?: string;
"MF-Dispatch-Namespace-Options"?: string;
};

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,11 +19,7 @@ export default class Client extends WorkerEntrypoint<RemoteBindingEnv> {
super(ctx, env);

const stub = env.remoteProxyConnectionString
? makeRemoteProxyStub(
env.remoteProxyConnectionString,
env.binding,
env.bindingType ? { "MF-Binding-Type": env.bindingType } : undefined
)
? makeRemoteProxyStub(env.remoteProxyConnectionString, env.binding)
: undefined;

return new Proxy(this, {
Expand Down
2 changes: 1 addition & 1 deletion packages/wrangler/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@
"miniflare": "workspace:*",
"path-to-regexp": "6.3.0",
"unenv": "2.0.0-rc.24",
"workerd": "1.20260226.1"
"workerd": "1.20260301.1"
},
"devDependencies": {
"@aws-sdk/client-s3": "^3.721.0",
Expand Down
Loading
Loading