@ea-lab/reactive-json 0.0.40 → 0.0.41
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/.cursorrules +11 -0
- package/README.md +1 -1
- package/README_LLM.md +2 -0
- package/package.json +1 -1
package/.cursorrules
CHANGED
|
@@ -30,6 +30,17 @@
|
|
|
30
30
|
- For **creating/developing** React components → use `extend/component-development.md`
|
|
31
31
|
- For **using/configuring** components in JSON/YAML → use `core/[category]/`
|
|
32
32
|
|
|
33
|
+
## Plugin System Requirements
|
|
34
|
+
|
|
35
|
+
**⚠️ CRITICAL**: When using custom components as plugins, `mergeComponentCollections([...])` is **MANDATORY** - even for a single plugin collection. The reactive-json plugin system will NOT work without it.
|
|
36
|
+
|
|
37
|
+
```js
|
|
38
|
+
import {ReactiveJsonRoot, mergeComponentCollections} from "@ea-lab/reactive-json";
|
|
39
|
+
|
|
40
|
+
const plugins = mergeComponentCollections([customPlugins]); // REQUIRED
|
|
41
|
+
return <ReactiveJsonRoot {...props} plugins={plugins} />;
|
|
42
|
+
```
|
|
43
|
+
|
|
33
44
|
## Component Validation Rules
|
|
34
45
|
|
|
35
46
|
1. For each component, STRICTLY verify:
|
package/README.md
CHANGED
|
@@ -108,7 +108,7 @@ The `ReactiveJsonRoot` component accepts the following properties:
|
|
|
108
108
|
- `dataUrl`: The URL of the document containing the build data (JSON or YAML)
|
|
109
109
|
- `dataFetchMethod`: The fetch method for the data ("GET" or "POST", case-insensitive)
|
|
110
110
|
- `headersForData`: Headers for the data request (e.g., authentication info)
|
|
111
|
-
- `plugins`: Reactive-JSON plugins to extend functionality
|
|
111
|
+
- `plugins`: Reactive-JSON plugins to extend functionality (**must** use `mergeComponentCollections`)
|
|
112
112
|
- `debugMode`: Debug mode to show the data structure and debug info
|
|
113
113
|
- `maybeRawAppData`: A RjBuild configuration to initialize directly (string or object)
|
|
114
114
|
|
package/README_LLM.md
CHANGED
|
@@ -316,6 +316,8 @@ export const CustomRoot = (props) => {
|
|
|
316
316
|
};
|
|
317
317
|
```
|
|
318
318
|
|
|
319
|
+
**⚠️ CRITICAL**: `mergeComponentCollections([...])` is **mandatory** even when you have only a single plugin collection. The reactive-json plugin system will not work without it.
|
|
320
|
+
|
|
319
321
|
### Plugin Structure
|
|
320
322
|
```js
|
|
321
323
|
{
|