@arcote.tech/arc-react 0.7.32 → 0.8.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.
- package/dist/index.js +4 -2
- package/dist/src/options.d.ts +7 -0
- package/package.json +2 -2
package/dist/index.js
CHANGED
|
@@ -334,7 +334,9 @@ var modelProviderFactory = (context, options) => {
|
|
|
334
334
|
enableEventSync: !!options.dbAdapterFactory
|
|
335
335
|
}) : undefined;
|
|
336
336
|
const queryWire = options.remoteUrl ? new QueryWire(options.remoteUrl) : undefined;
|
|
337
|
-
const authAdapter = new AuthAdapter
|
|
337
|
+
const authAdapter = new AuthAdapter({
|
|
338
|
+
storageNamespace: options.tokenStorageNamespace
|
|
339
|
+
});
|
|
338
340
|
authAdapter.loadPersisted();
|
|
339
341
|
let initialized = false;
|
|
340
342
|
let cachedModel = null;
|
|
@@ -700,4 +702,4 @@ export {
|
|
|
700
702
|
Form
|
|
701
703
|
};
|
|
702
704
|
|
|
703
|
-
//# debugId=
|
|
705
|
+
//# debugId=B566EF6E3F73DF0C64756E2164756E21
|
package/dist/src/options.d.ts
CHANGED
|
@@ -2,5 +2,12 @@ import type { DBAdapterFactory } from "@arcote.tech/arc";
|
|
|
2
2
|
export type ReactModelOptions = {
|
|
3
3
|
dbAdapterFactory?: DBAdapterFactory;
|
|
4
4
|
remoteUrl?: string;
|
|
5
|
+
/**
|
|
6
|
+
* Namespace persystencji tokenów (`arc:token:<ns>:<scope>`). Wymagany, gdy
|
|
7
|
+
* na jednej stronie żyje WIĘCEJ NIŻ JEDEN model (federacja modułów): modele
|
|
8
|
+
* host i aplikacji partnerskich mogą używać tej samej nazwy scope
|
|
9
|
+
* ("workspace") — bez namespace nadpisywałyby sobie tokeny w localStorage.
|
|
10
|
+
*/
|
|
11
|
+
tokenStorageNamespace?: string;
|
|
5
12
|
};
|
|
6
13
|
//# sourceMappingURL=options.d.ts.map
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@arcote.tech/arc-react",
|
|
3
3
|
"type": "module",
|
|
4
|
-
"version": "0.
|
|
4
|
+
"version": "0.8.1",
|
|
5
5
|
"private": false,
|
|
6
6
|
"author": "Przemysław Krasiński [arcote.tech]",
|
|
7
7
|
"description": "React client for the Arc framework, providing utilities for querying data and executing commands, enhancing the development of reactive and efficient user interfaces.",
|
|
@@ -32,7 +32,7 @@
|
|
|
32
32
|
"typescript": "^5.2.2"
|
|
33
33
|
},
|
|
34
34
|
"peerDependencies": {
|
|
35
|
-
"@arcote.tech/arc": "^0.
|
|
35
|
+
"@arcote.tech/arc": "^0.8.1",
|
|
36
36
|
"react": "^18.0.0 || ^19.0.0",
|
|
37
37
|
"react-dom": "^18.0.0 || ^19.0.0",
|
|
38
38
|
"typescript": "^5.0.0"
|