create-cloudflare 2.51.0 → 2.51.1

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/dist/cli.js CHANGED
@@ -78503,7 +78503,7 @@ var Yargs = YargsFactory(esm_default);
78503
78503
  var yargs_default = Yargs;
78504
78504
 
78505
78505
  // package.json
78506
- var version = "2.51.0";
78506
+ var version = "2.51.1";
78507
78507
 
78508
78508
  // src/metrics.ts
78509
78509
  var import_node_async_hooks = require("node:async_hooks");
@@ -81957,7 +81957,7 @@ var c3_default50 = config46;
81957
81957
  var import_node_assert2 = __toESM(require("node:assert"));
81958
81958
 
81959
81959
  // ../wrangler/package.json
81960
- var version2 = "4.31.0";
81960
+ var version2 = "4.33.0";
81961
81961
 
81962
81962
  // src/git.ts
81963
81963
  var offerGit = async (ctx) => {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "create-cloudflare",
3
- "version": "2.51.0",
3
+ "version": "2.51.1",
4
4
  "description": "A CLI for creating and deploying new applications to Cloudflare.",
5
5
  "keywords": [
6
6
  "cloudflare",
@@ -30,7 +30,7 @@
30
30
  "@babel/parser": "^7.21.3",
31
31
  "@babel/types": "^7.21.4",
32
32
  "@clack/prompts": "^0.6.3",
33
- "@cloudflare/workers-types": "^4.20250816.0",
33
+ "@cloudflare/workers-types": "^4.20250823.0",
34
34
  "@iarna/toml": "^3.0.0",
35
35
  "@types/command-exists": "^1.2.0",
36
36
  "@types/cross-spawn": "^6.0.2",
@@ -73,11 +73,11 @@
73
73
  "xdg-app-paths": "^8.3.0",
74
74
  "yargs": "^17.7.2",
75
75
  "@cloudflare/cli": "1.1.1",
76
+ "@cloudflare/vite-plugin": "1.12.0",
77
+ "@cloudflare/eslint-config-worker": "1.1.0",
76
78
  "@cloudflare/mock-npm-registry": "0.0.0",
77
- "@cloudflare/vite-plugin": "1.11.6",
78
79
  "@cloudflare/workers-tsconfig": "0.0.0",
79
- "@cloudflare/eslint-config-worker": "1.1.0",
80
- "wrangler": "4.31.0"
80
+ "wrangler": "4.33.0"
81
81
  },
82
82
  "engines": {
83
83
  "node": ">=18.14.1"
@@ -52,17 +52,15 @@ export default {
52
52
  * @returns {Promise<Response>} The response to be sent back to the client
53
53
  */
54
54
  async fetch(request, env, ctx) {
55
- // Create a `DurableObjectId` for an instance of the `MyDurableObject`
56
- // class named "foo". Requests from all Workers to the instance named
57
- // "foo" will go to a single globally unique Durable Object instance.
58
- const id = env.MY_DURABLE_OBJECT.idFromName("foo");
59
-
60
- // Create a stub to open a communication channel with the Durable
61
- // Object instance.
62
- const stub = env.MY_DURABLE_OBJECT.get(id);
55
+ // Create a stub to open a communication channel with the Durable Object
56
+ // instance named "foo".
57
+ //
58
+ // Requests from all Workers to the Durable Object instance named "foo"
59
+ // will go to a single remote Durable Object instance.
60
+ const stub = env.MY_DURABLE_OBJECT.getByName("foo");
63
61
 
64
62
  // Call the `sayHello()` RPC method on the stub to invoke the method on
65
- // the remote Durable Object instance
63
+ // the remote Durable Object instance.
66
64
  const greeting = await stub.sayHello("world");
67
65
 
68
66
  return new Response(greeting);
@@ -50,17 +50,15 @@ class Default(WorkerEntrypoint):
50
50
  * @returns {Promise<Response>} The response to be sent back to the client
51
51
  """
52
52
  async def fetch(self, request):
53
- # Create a `DurableObjectId` for an instance of the `MyDurableObject`
54
- # class named "foo". Requests from all Workers to the instance named
55
- # "foo" will go to a single globally unique Durable Object instance.
56
- id = self.env.MY_DURABLE_OBJECT.idFromName("foo")
53
+ # Create a stub to open a communication channel with the Durable Object
54
+ # instance named "foo".
55
+ #
56
+ # Requests from all Workers to the Durable Object instance named "foo"
57
+ # will go to a single remote Durable Object instance.
58
+ stub = self.env.MY_DURABLE_OBJECT.getByName("foo")
57
59
 
58
- # Create a stub to open a communication channel with the Durable
59
- # Object instance.
60
- stub = self.env.MY_DURABLE_OBJECT.get(id)
61
-
62
- # Call the `say_hello()` RPC method on the stub to invoke the method on
63
- # the remote Durable Object instance
60
+ # Call the `say_hello()` RPC method on the stub to invoke the method on
61
+ # the remote Durable Object instance.
64
62
  greeting = await stub.say_hello("world")
65
63
 
66
64
  return Response(greeting)
@@ -48,17 +48,15 @@ export default {
48
48
  * @returns The response to be sent back to the client
49
49
  */
50
50
  async fetch(request, env, ctx): Promise<Response> {
51
- // Create a `DurableObjectId` for an instance of the `MyDurableObject`
52
- // class named "foo". Requests from all Workers to the instance named
53
- // "foo" will go to a single globally unique Durable Object instance.
54
- const id: DurableObjectId = env.MY_DURABLE_OBJECT.idFromName("foo");
55
-
56
- // Create a stub to open a communication channel with the Durable
57
- // Object instance.
58
- const stub = env.MY_DURABLE_OBJECT.get(id);
51
+ // Create a stub to open a communication channel with the Durable Object
52
+ // instance named "foo".
53
+ //
54
+ // Requests from all Workers to the Durable Object instance named "foo"
55
+ // will go to a single remote Durable Object instance.
56
+ const stub = env.MY_DURABLE_OBJECT.getByName("foo");
59
57
 
60
58
  // Call the `sayHello()` RPC method on the stub to invoke the method on
61
- // the remote Durable Object instance
59
+ // the remote Durable Object instance.
62
60
  const greeting = await stub.sayHello("world");
63
61
 
64
62
  return new Response(greeting);
@@ -52,17 +52,15 @@ export default {
52
52
  * @returns {Promise<Response>} The response to be sent back to the client
53
53
  */
54
54
  async fetch(request, env, ctx) {
55
- // Create a `DurableObjectId` for an instance of the `MyDurableObject`
56
- // class named "foo". Requests from all Workers to the instance named
57
- // "foo" will go to a single globally unique Durable Object instance.
58
- const id = env.MY_DURABLE_OBJECT.idFromName("foo");
59
-
60
- // Create a stub to open a communication channel with the Durable
61
- // Object instance.
62
- const stub = env.MY_DURABLE_OBJECT.get(id);
55
+ // Create a stub to open a communication channel with the Durable Object
56
+ // instance named "foo".
57
+ //
58
+ // Requests from all Workers to the Durable Object instance named "foo"
59
+ // will go to a single remote Durable Object instance.
60
+ const stub = env.MY_DURABLE_OBJECT.getByName("foo");
63
61
 
64
62
  // Call the `sayHello()` RPC method on the stub to invoke the method on
65
- // the remote Durable Object instance
63
+ // the remote Durable Object instance.
66
64
  const greeting = await stub.sayHello("world");
67
65
 
68
66
  return new Response(greeting);
@@ -50,17 +50,15 @@ class MyDurableObject(DurableObject):
50
50
  """
51
51
  class Default(WorkerEntrypoint):
52
52
  async def fetch(self, request):
53
- # Create a `DurableObjectId` for an instance of the `MyDurableObject`
54
- # class named "foo". Requests from all Workers to the instance named
55
- # "foo" will go to a single globally unique Durable Object instance.
56
- id = self.env.MY_DURABLE_OBJECT.idFromName("foo")
53
+ # Create a stub to open a communication channel with the Durable Object
54
+ # instance named "foo".
55
+ #
56
+ # Requests from all Workers to the Durable Object instance named "foo"
57
+ # will go to a single remote Durable Object instance.
58
+ stub = self.env.MY_DURABLE_OBJECT.getByName("foo")
57
59
 
58
- # Create a stub to open a communication channel with the Durable
59
- # Object instance.
60
- stub = self.env.MY_DURABLE_OBJECT.get(id)
61
-
62
- # Call the `say_hello()` RPC method on the stub to invoke the method on
63
- # the remote Durable Object instance
60
+ # Call the `say_hello()` RPC method on the stub to invoke the method on
61
+ # the remote Durable Object instance.
64
62
  greeting = await stub.say_hello("world")
65
63
 
66
64
  return Response(greeting)
@@ -49,17 +49,15 @@ export default {
49
49
  * @returns The response to be sent back to the client
50
50
  */
51
51
  async fetch(request, env, ctx): Promise<Response> {
52
- // Create a `DurableObjectId` for an instance of the `MyDurableObject`
53
- // class named "foo". Requests from all Workers to the instance named
54
- // "foo" will go to a single globally unique Durable Object instance.
55
- const id: DurableObjectId = env.MY_DURABLE_OBJECT.idFromName("foo");
56
-
57
- // Create a stub to open a communication channel with the Durable
58
- // Object instance.
59
- const stub = env.MY_DURABLE_OBJECT.get(id);
52
+ // Create a stub to open a communication channel with the Durable Object
53
+ // instance named "foo".
54
+ //
55
+ // Requests from all Workers to the Durable Object instance named "foo"
56
+ // will go to a single remote Durable Object instance.
57
+ const stub = env.MY_DURABLE_OBJECT.getByName("foo");
60
58
 
61
59
  // Call the `sayHello()` RPC method on the stub to invoke the method on
62
- // the remote Durable Object instance
60
+ // the remote Durable Object instance.
63
61
  const greeting = await stub.sayHello("world");
64
62
 
65
63
  return new Response(greeting);