@sovereignfs/create 0.18.0 → 0.19.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/dist/create.mjs +3 -2
- package/package.json +1 -1
- package/template/app/lib/sovereign.ts +9 -1
package/dist/create.mjs
CHANGED
|
@@ -7,7 +7,7 @@ import { createInterface } from "readline/promises";
|
|
|
7
7
|
// package.json
|
|
8
8
|
var package_default = {
|
|
9
9
|
name: "@sovereignfs/create",
|
|
10
|
-
version: "0.
|
|
10
|
+
version: "0.19.0",
|
|
11
11
|
type: "module",
|
|
12
12
|
description: "npm create @sovereignfs: makes an instance repository, pinned to the toolkit (sv) of the same version.",
|
|
13
13
|
license: "AGPL-3.0-or-later",
|
|
@@ -322,7 +322,8 @@ var APP_DEPENDENCIES = {
|
|
|
322
322
|
"@dnd-kit/sortable": "^10.0.0",
|
|
323
323
|
"@sovereignfs/config": "^0.1.0",
|
|
324
324
|
"@sovereignfs/pwa": "^0.1.0",
|
|
325
|
-
|
|
325
|
+
// 2.8 checks a session against core (`checkEverySeconds`), which the template turns on.
|
|
326
|
+
"@sovereignfs/sdk": "^2.8.0",
|
|
326
327
|
"@sovereignfs/storage": "^0.1.0",
|
|
327
328
|
"@sovereignfs/ui": "^0.101.0",
|
|
328
329
|
next: "^16.4.6",
|
package/package.json
CHANGED
|
@@ -6,8 +6,16 @@ let client: Sovereign | undefined;
|
|
|
6
6
|
/**
|
|
7
7
|
* The one client for this process. It reads __PREFIX___URL, __PREFIX___CORE_URL, __PREFIX___CORE_CLIENT_ID and __PREFIX___CORE_CLIENT_SECRET,
|
|
8
8
|
* makes no call to core, and is made when first used, so building the app needs none of them.
|
|
9
|
+
*
|
|
10
|
+
* A person's session here is checked against core every hour: the next page they open after that goes through core, which shows
|
|
11
|
+
* nothing while they are still signed in there and asks them to sign in when they are not, and brings their name and roles up to date.
|
|
9
12
|
*/
|
|
10
13
|
export function sovereign(): Sovereign {
|
|
11
|
-
client ??= createSovereign({
|
|
14
|
+
client ??= createSovereign({
|
|
15
|
+
prefix: '__PREFIX__',
|
|
16
|
+
sessionStore,
|
|
17
|
+
tokenStore,
|
|
18
|
+
checkEverySeconds: 60 * 60,
|
|
19
|
+
});
|
|
12
20
|
return client;
|
|
13
21
|
}
|