@ossy/app 1.25.2 → 1.26.0
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 +19 -0
- package/package.json +10 -10
package/README.md
CHANGED
|
@@ -111,6 +111,25 @@ The worker polls the job queue every 3 seconds and lazy-imports the handler modu
|
|
|
111
111
|
|
|
112
112
|
Build output: `build/.ossy/tasks.generated.json` — a registry of `[{ type, module }]` entries. Run the worker with `node build/worker.js`. Requires `OSSY_WORKSPACE_ID`, `OSSY_API_URL`, and `OSSY_API_TOKEN` environment variables.
|
|
113
113
|
|
|
114
|
+
## Components (`*.component.jsx`)
|
|
115
|
+
|
|
116
|
+
Create `*.component.jsx` files in `src/` (or in any package dependency) to register slot-injectable components. The build discovers them automatically and bundles them separately — they are loaded on every page and slotted in by the layout when `metadata.id` matches the active page id.
|
|
117
|
+
|
|
118
|
+
```jsx
|
|
119
|
+
// src/workspace-users.component.jsx
|
|
120
|
+
export const metadata = {
|
|
121
|
+
id: 'workspace/users', // rendered when pageId === 'workspace/users'
|
|
122
|
+
}
|
|
123
|
+
|
|
124
|
+
export default function WorkspaceUsersContent() {
|
|
125
|
+
return <div>Users content</div>
|
|
126
|
+
}
|
|
127
|
+
```
|
|
128
|
+
|
|
129
|
+
In your layout, use `<Slot name={app?.pageId} fallback={children} />` from `@ossy/design-system` to render the matching component (or fall back to the page's own output).
|
|
130
|
+
|
|
131
|
+
See [`docs/component-primitive.md`](./docs/component-primitive.md) for the full contract, flow diagram, and examples.
|
|
132
|
+
|
|
114
133
|
## Port configuration
|
|
115
134
|
|
|
116
135
|
The server listens on port **3000** by default.
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@ossy/app",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.26.0",
|
|
4
4
|
"description": "",
|
|
5
5
|
"source": "./src/index.js",
|
|
6
6
|
"main": "./src/index.js",
|
|
@@ -37,15 +37,15 @@
|
|
|
37
37
|
"@babel/eslint-parser": "^7.15.8",
|
|
38
38
|
"@babel/preset-react": "^7.26.3",
|
|
39
39
|
"@babel/register": "^7.25.9",
|
|
40
|
-
"@ossy/connected-components": "^1.
|
|
41
|
-
"@ossy/design-system": "^1.
|
|
40
|
+
"@ossy/connected-components": "^1.26.0",
|
|
41
|
+
"@ossy/design-system": "^1.26.0",
|
|
42
42
|
"@ossy/pages": "^1.23.0",
|
|
43
|
-
"@ossy/platform": "^1.
|
|
44
|
-
"@ossy/router": "^1.
|
|
45
|
-
"@ossy/router-react": "^1.
|
|
46
|
-
"@ossy/sdk": "^1.
|
|
47
|
-
"@ossy/sdk-react": "^1.
|
|
48
|
-
"@ossy/themes": "^1.
|
|
43
|
+
"@ossy/platform": "^1.25.0",
|
|
44
|
+
"@ossy/router": "^1.26.0",
|
|
45
|
+
"@ossy/router-react": "^1.26.0",
|
|
46
|
+
"@ossy/sdk": "^1.26.0",
|
|
47
|
+
"@ossy/sdk-react": "^1.26.0",
|
|
48
|
+
"@ossy/themes": "^1.26.0",
|
|
49
49
|
"@rollup/plugin-alias": "^6.0.0",
|
|
50
50
|
"@rollup/plugin-babel": "^7.0.0",
|
|
51
51
|
"@rollup/plugin-commonjs": "^29.0.0",
|
|
@@ -79,5 +79,5 @@
|
|
|
79
79
|
"README.md",
|
|
80
80
|
"tsconfig.json"
|
|
81
81
|
],
|
|
82
|
-
"gitHead": "
|
|
82
|
+
"gitHead": "40e96d148d991ef4ad60fe9090f19b836ff8eb00"
|
|
83
83
|
}
|