@platformatic/react-router 3.31.0 → 3.32.0-alpha.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.
Files changed (3) hide show
  1. package/config.d.ts +12 -0
  2. package/package.json +6 -6
  3. package/schema.json +21 -1
package/config.d.ts CHANGED
@@ -293,6 +293,18 @@ export interface PlatformaticReactRouterConfig {
293
293
  maxSize?: number;
294
294
  maxEntrySize?: number;
295
295
  maxCount?: number;
296
+ /**
297
+ * Whitelist of origins to cache. Supports exact strings and regex patterns (e.g., "/https:\\/\\/.*\\.example\\.com/").
298
+ */
299
+ origins?: string[];
300
+ /**
301
+ * Default cache duration in seconds for responses without explicit expiration headers.
302
+ */
303
+ cacheByDefault?: number;
304
+ /**
305
+ * Cache type. "shared" caches may be shared between users, "private" caches are user-specific.
306
+ */
307
+ type?: "shared" | "private";
296
308
  [k: string]: unknown;
297
309
  };
298
310
  watch?: boolean | string;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@platformatic/react-router",
3
- "version": "3.31.0",
3
+ "version": "3.32.0-alpha.1",
4
4
  "description": "Platformatic React Router Capability",
5
5
  "main": "index.js",
6
6
  "type": "module",
@@ -18,9 +18,9 @@
18
18
  "@fastify/static": "^8.0.0",
19
19
  "fastify": "^5.7.0",
20
20
  "semver": "^7.6.3",
21
- "@platformatic/foundation": "3.31.0",
22
- "@platformatic/basic": "3.31.0",
23
- "@platformatic/vite": "3.31.0"
21
+ "@platformatic/basic": "3.32.0-alpha.1",
22
+ "@platformatic/vite": "3.32.0-alpha.1",
23
+ "@platformatic/foundation": "3.32.0-alpha.1"
24
24
  },
25
25
  "devDependencies": {
26
26
  "@react-router/dev": "^7.10.0",
@@ -40,8 +40,8 @@
40
40
  "typescript": "^5.5.4",
41
41
  "vite": "^7.1.7",
42
42
  "ws": "^8.18.0",
43
- "@platformatic/gateway": "3.31.0",
44
- "@platformatic/service": "3.31.0"
43
+ "@platformatic/gateway": "3.32.0-alpha.1",
44
+ "@platformatic/service": "3.32.0-alpha.1"
45
45
  },
46
46
  "engines": {
47
47
  "node": ">=22.19.0"
package/schema.json CHANGED
@@ -1,5 +1,5 @@
1
1
  {
2
- "$id": "https://schemas.platformatic.dev/@platformatic/react-router/3.31.0.json",
2
+ "$id": "https://schemas.platformatic.dev/@platformatic/react-router/3.32.0-alpha.1.json",
3
3
  "$schema": "http://json-schema.org/draft-07/schema#",
4
4
  "title": "Platformatic React Router Config",
5
5
  "type": "object",
@@ -1363,6 +1363,26 @@
1363
1363
  },
1364
1364
  "maxCount": {
1365
1365
  "type": "integer"
1366
+ },
1367
+ "origins": {
1368
+ "type": "array",
1369
+ "items": {
1370
+ "type": "string"
1371
+ },
1372
+ "description": "Whitelist of origins to cache. Supports exact strings and regex patterns (e.g., \"/https:\\\\/\\\\/.*\\\\.example\\\\.com/\")."
1373
+ },
1374
+ "cacheByDefault": {
1375
+ "type": "integer",
1376
+ "description": "Default cache duration in seconds for responses without explicit expiration headers."
1377
+ },
1378
+ "type": {
1379
+ "type": "string",
1380
+ "enum": [
1381
+ "shared",
1382
+ "private"
1383
+ ],
1384
+ "default": "shared",
1385
+ "description": "Cache type. \"shared\" caches may be shared between users, \"private\" caches are user-specific."
1366
1386
  }
1367
1387
  }
1368
1388
  }