playcademy 0.13.9 → 0.13.11
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/constants.d.ts +2 -0
- package/dist/constants.js +3 -1
- package/dist/db.js +3 -1
- package/dist/edge-play/src/types.ts +10 -4
- package/dist/index.d.ts +2 -0
- package/dist/index.js +928 -210
- package/dist/templates/api/sample-bucket.ts.template +178 -0
- package/dist/templates/api/sample-custom.ts.template +0 -2
- package/dist/templates/api/sample-database.ts.template +5 -3
- package/dist/templates/api/sample-kv.ts.template +0 -2
- package/dist/templates/api/sample-route-with-db.ts.template +0 -2
- package/dist/templates/api/sample-route.ts.template +0 -1
- package/dist/templates/gitignore.template +3 -3
- package/dist/templates/playcademy-env.d.ts.template +16 -0
- package/dist/templates/playcademy-gitignore.template +4 -0
- package/dist/utils.d.ts +2 -0
- package/dist/utils.js +205 -50
- package/package.json +1 -1
package/dist/constants.d.ts
CHANGED
|
@@ -49,6 +49,8 @@ declare const CLI_DIRECTORIES: {
|
|
|
49
49
|
readonly DATABASE: string;
|
|
50
50
|
/** KV storage directory within workspace */
|
|
51
51
|
readonly KV: string;
|
|
52
|
+
/** Bucket storage directory within workspace */
|
|
53
|
+
readonly BUCKET: string;
|
|
52
54
|
};
|
|
53
55
|
/**
|
|
54
56
|
* CLI user directories (in home directory)
|
package/dist/constants.js
CHANGED
|
@@ -20,7 +20,9 @@ var CLI_DIRECTORIES = {
|
|
|
20
20
|
/** Database directory within workspace */
|
|
21
21
|
DATABASE: join(WORKSPACE_NAME, "db"),
|
|
22
22
|
/** KV storage directory within workspace */
|
|
23
|
-
KV: join(WORKSPACE_NAME, "kv")
|
|
23
|
+
KV: join(WORKSPACE_NAME, "kv"),
|
|
24
|
+
/** Bucket storage directory within workspace */
|
|
25
|
+
BUCKET: join(WORKSPACE_NAME, "bucket")
|
|
24
26
|
};
|
|
25
27
|
var CLI_USER_DIRECTORIES = {
|
|
26
28
|
/** User config directory for auth, games store, etc. */
|
package/dist/db.js
CHANGED
|
@@ -32,7 +32,9 @@ var CLI_DIRECTORIES = {
|
|
|
32
32
|
/** Database directory within workspace */
|
|
33
33
|
DATABASE: join(WORKSPACE_NAME, "db"),
|
|
34
34
|
/** KV storage directory within workspace */
|
|
35
|
-
KV: join(WORKSPACE_NAME, "kv")
|
|
35
|
+
KV: join(WORKSPACE_NAME, "kv"),
|
|
36
|
+
/** Bucket storage directory within workspace */
|
|
37
|
+
BUCKET: join(WORKSPACE_NAME, "bucket")
|
|
36
38
|
};
|
|
37
39
|
var CLI_FILES = {
|
|
38
40
|
/** Auth store file in user config directory */
|
|
@@ -7,6 +7,8 @@
|
|
|
7
7
|
* - Route handler signatures
|
|
8
8
|
*/
|
|
9
9
|
|
|
10
|
+
/// <reference types="@cloudflare/workers-types" />
|
|
11
|
+
|
|
10
12
|
import type { PlaycademyClient, PlaycademyConfig } from '@playcademy/sdk/server'
|
|
11
13
|
|
|
12
14
|
/**
|
|
@@ -33,10 +35,14 @@ export interface ServerEnv {
|
|
|
33
35
|
/** Platform base URL (stage-aware: hub.playcademy.net or hub.dev.playcademy.net) */
|
|
34
36
|
PLAYCADEMY_BASE_URL: string
|
|
35
37
|
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
38
|
+
/** KV namespace binding (optional, Cloudflare-specific) */
|
|
39
|
+
KV?: KVNamespace
|
|
40
|
+
|
|
41
|
+
/** D1 database binding (optional, Cloudflare-specific) */
|
|
42
|
+
DB?: D1Database
|
|
43
|
+
|
|
44
|
+
/** R2 bucket binding (optional, Cloudflare-specific) */
|
|
45
|
+
BUCKET?: R2Bucket
|
|
40
46
|
}
|
|
41
47
|
|
|
42
48
|
/**
|
package/dist/index.d.ts
CHANGED