@localess/react 3.0.5 → 3.0.6-dev.20260506093132

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/README.md CHANGED
@@ -112,7 +112,8 @@ localessInit({
112
112
  | `token` | `string` | ✅ | — | Localess API token (keep secret — server-side only) |
113
113
  | `version` | `'draft' \| string` | ❌ | `'published'` | Default content version |
114
114
  | `debug` | `boolean` | ❌ | `false` | Enable debug logging |
115
- | `cacheTTL` | `number \| false` | ❌ | `300000` | Cache TTL in milliseconds. Set `false` to disable |
115
+ | `cacheTTL` | `number \| false` | ❌ | `300` | Cache TTL in **seconds** (default: 5 minutes). Set `false` to disable caching entirely — takes precedence over `fileSystemCache` |
116
+ | `fileSystemCache` | `boolean` | ❌ | `false` | Use a file-system cache instead of the default in-memory cache. Shared across all processes pointing to the same working directory (e.g. Next.js parallel build workers). Respects `cacheTTL` for TTL value |
116
117
  | `components` | `Record<string, React.ElementType>` | ❌ | `{}` | Map of schema keys to React components |
117
118
  | `fallbackComponent` | `React.ElementType` | ❌ | — | Component rendered when a schema key has no registered component |
118
119
  | `enableSync` | `boolean` | ❌ | `false` | Load the Visual Editor sync script for live-editing support |
package/SKILL.md CHANGED
@@ -37,7 +37,8 @@ localessInit({
37
37
 
38
38
  // Optional client settings
39
39
  version: 'draft', // undefined = published (default), 'draft' for preview
40
- cacheTTL: 300000, // 5 minutes default
40
+ cacheTTL: 300, // Cache TTL in seconds; false to disable; default: 300 (5 min)
41
+ fileSystemCache: false, // true = share cache across processes (e.g. Next.js build workers)
41
42
  debug: false,
42
43
 
43
44
  // React-specific options
@@ -4,7 +4,7 @@ export type { LocalessClient } from '@localess/client';
4
4
  /**
5
5
  * Initialization options for {@link localessInit}.
6
6
  *
7
- * Extends {@link LocalessClientOptions} (origin, spaceId, token, version, debug, cacheTTL)
7
+ * Extends {@link LocalessClientOptions} (origin, spaceId, token, version, debug, cacheTTL, fileSystemCache)
8
8
  * with React-specific settings for component mapping and Visual Editor sync.
9
9
  */
10
10
  export type LocalessOptions = LocalessClientOptions & {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@localess/react",
3
- "version": "3.0.5",
3
+ "version": "3.0.6-dev.20260506093132",
4
4
  "description": "ReactJS JavaScript/TypeScript SDK for Localess's API.",
5
5
  "keywords": [
6
6
  "localess",
@@ -61,7 +61,7 @@
61
61
  "react-dom": "^17 || ^18 || ^19"
62
62
  },
63
63
  "dependencies": {
64
- "@localess/client": "3.0.5",
64
+ "@localess/client": "3.0.6-dev.20260506093132",
65
65
  "@tiptap/extension-bold": "^3.22.5",
66
66
  "@tiptap/extension-bullet-list": "^3.22.5",
67
67
  "@tiptap/extension-code": "^3.22.5",