From a602de088c1b450ea62e84d48df7189f2443f127 Mon Sep 17 00:00:00 2001 From: Dario Piotrowicz Date: Thu, 19 Sep 2024 13:20:40 +0100 Subject: [PATCH] C3: bump qwik to `1.9.0` (#6755) * fix: add missing `nodejs_compat` flag to c3 qwik template The c3 qwik template doesn't include the `nodejs_compat` but qwik seems to be using AsyncLocalStorage, so newly created applications do display a warning regarding it missing, fix the above issue by adding the missing compat flag * chore: bump create-qwik from 1.5.7 to 1.9.0 in `/packages/create-cloudflare/src/frameworks` As part of this update the 'basic' template to its new name 'playground' (renamed in https://github.com/QwikDev/qwik/pull/6632) --- .changeset/few-feet-appear.md | 9 +++++++++ .changeset/spotty-snails-design.md | 11 +++++++++++ .../create-cloudflare/src/frameworks/package.json | 2 +- .../templates-experimental/qwik/c3.ts | 2 +- packages/create-cloudflare/templates/qwik/c3.ts | 2 +- .../templates/qwik/templates/wrangler.toml | 1 + 6 files changed, 24 insertions(+), 3 deletions(-) create mode 100644 .changeset/few-feet-appear.md create mode 100644 .changeset/spotty-snails-design.md diff --git a/.changeset/few-feet-appear.md b/.changeset/few-feet-appear.md new file mode 100644 index 000000000000..d06bbd6e8fdd --- /dev/null +++ b/.changeset/few-feet-appear.md @@ -0,0 +1,9 @@ +--- +"create-cloudflare": patch +--- + +fix: add missing `nodejs_compat` flag to c3 qwik template + +The c3 qwik template doesn't include the `nodejs_compat` but qwik seems to be using +AsyncLocalStorage, so newly created applications do display a warning regarding it +missing, fix the above issue by adding the missing compat flag diff --git a/.changeset/spotty-snails-design.md b/.changeset/spotty-snails-design.md new file mode 100644 index 000000000000..2946f235368b --- /dev/null +++ b/.changeset/spotty-snails-design.md @@ -0,0 +1,11 @@ +--- +"create-cloudflare": patch +--- + +- chore: update dependencies of "create-cloudflare" package + + The following dependency versions have been updated: + + | Dependency | From | To | + | ----------- | ----- | ----- | + | create-qwik | 1.5.7 | 1.9.0 | diff --git a/packages/create-cloudflare/src/frameworks/package.json b/packages/create-cloudflare/src/frameworks/package.json index 98643f93be67..a1457c633677 100644 --- a/packages/create-cloudflare/src/frameworks/package.json +++ b/packages/create-cloudflare/src/frameworks/package.json @@ -11,7 +11,7 @@ "create-docusaurus": "3.5.2", "create-hono": "0.12.0", "create-next-app": "14.2.5", - "create-qwik": "1.5.7", + "create-qwik": "1.9.0", "create-vite": "5.2.3", "create-remix": "2.11.1", "create-solid": "0.5.12", diff --git a/packages/create-cloudflare/templates-experimental/qwik/c3.ts b/packages/create-cloudflare/templates-experimental/qwik/c3.ts index b5b4a5d955c9..b3fe6b4ef4b4 100644 --- a/packages/create-cloudflare/templates-experimental/qwik/c3.ts +++ b/packages/create-cloudflare/templates-experimental/qwik/c3.ts @@ -13,7 +13,7 @@ import type { C3Context } from "types"; const { npm, npx } = detectPackageManager(); const generate = async (ctx: C3Context) => { - await runFrameworkGenerator(ctx, ["basic", ctx.project.name]); + await runFrameworkGenerator(ctx, ["playground", ctx.project.name]); }; const configure = async (ctx: C3Context) => { diff --git a/packages/create-cloudflare/templates/qwik/c3.ts b/packages/create-cloudflare/templates/qwik/c3.ts index a39e94f302a6..a699c084407a 100644 --- a/packages/create-cloudflare/templates/qwik/c3.ts +++ b/packages/create-cloudflare/templates/qwik/c3.ts @@ -13,7 +13,7 @@ import type { C3Context } from "types"; const { npm, npx } = detectPackageManager(); const generate = async (ctx: C3Context) => { - await runFrameworkGenerator(ctx, ["basic", ctx.project.name]); + await runFrameworkGenerator(ctx, ["playground", ctx.project.name]); }; const configure = async (ctx: C3Context) => { diff --git a/packages/create-cloudflare/templates/qwik/templates/wrangler.toml b/packages/create-cloudflare/templates/qwik/templates/wrangler.toml index a03a506b7081..f90e05ee2260 100644 --- a/packages/create-cloudflare/templates/qwik/templates/wrangler.toml +++ b/packages/create-cloudflare/templates/qwik/templates/wrangler.toml @@ -2,6 +2,7 @@ name = "" compatibility_date = "" pages_build_output_dir = "./dist" +compatibility_flags = ["nodejs_compat"] # Automatically place your workloads in an optimal location to minimize latency. # If you are running back-end logic in a Pages Function, running it closer to your back-end infrastructure