5htp-core 0.4.9-7 → 0.4.9-8
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/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "5htp-core",
|
|
3
3
|
"description": "Convenient TypeScript framework designed for Performance and Productivity.",
|
|
4
|
-
"version": "0.4.9-
|
|
4
|
+
"version": "0.4.9-8",
|
|
5
5
|
"author": "Gaetan Le Gac (https://github.com/gaetanlegac)",
|
|
6
6
|
"repository": "git://github.com/gaetanlegac/5htp-core.git",
|
|
7
7
|
"license": "MIT",
|
|
@@ -13,7 +13,6 @@
|
|
|
13
13
|
"framework"
|
|
14
14
|
],
|
|
15
15
|
"dependencies": {
|
|
16
|
-
"@excalidraw/excalidraw": "^0.17.6",
|
|
17
16
|
"@lexical/file": "^0.19.0",
|
|
18
17
|
"@lexical/headless": "^0.18.0",
|
|
19
18
|
"@lexical/html": "^0.18.0",
|
|
@@ -4,11 +4,11 @@
|
|
|
4
4
|
|
|
5
5
|
// Npm
|
|
6
6
|
import type { VNode } from 'preact';
|
|
7
|
+
import type { Thing } from 'schema-dts';
|
|
7
8
|
|
|
8
9
|
// Core libs
|
|
9
10
|
import { ClientOrServerRouter, TClientOrServerContext, TRoute, TErrorRoute } from '@common/router';
|
|
10
11
|
import { TFetcherList, TDataReturnedByFetchers } from '@common/router/request/api';
|
|
11
|
-
import { history } from '@client/services/router/request/history';
|
|
12
12
|
|
|
13
13
|
/*----------------------------------
|
|
14
14
|
- TYPES
|
|
@@ -50,7 +50,9 @@ export type TPageResource = {
|
|
|
50
50
|
} | {
|
|
51
51
|
url: string,
|
|
52
52
|
preload?: boolean
|
|
53
|
-
})
|
|
53
|
+
})
|
|
54
|
+
|
|
55
|
+
type TMetasList = ({ $: string } & { [key: string]: string })[]
|
|
54
56
|
|
|
55
57
|
const debug = false;
|
|
56
58
|
|
|
@@ -68,6 +70,9 @@ export default abstract class PageResponse<TRouter extends ClientOrServerRouter
|
|
|
68
70
|
public url: string;
|
|
69
71
|
|
|
70
72
|
// Resources
|
|
73
|
+
public head: TMetasList = [];
|
|
74
|
+
public metas: { [name: string]: string } = {};
|
|
75
|
+
public jsonld: Thing[] = [];
|
|
71
76
|
public scripts: TPageResource[] = [];
|
|
72
77
|
public style: TPageResource[] = [];
|
|
73
78
|
|
|
@@ -5,7 +5,6 @@
|
|
|
5
5
|
// Npm
|
|
6
6
|
import React from 'react';
|
|
7
7
|
import renderToString from "preact-render-to-string";
|
|
8
|
-
import type { Thing } from 'schema-dts';
|
|
9
8
|
|
|
10
9
|
// Core
|
|
11
10
|
import { default as Router, TRouterContext } from "@server/services/router";
|
|
@@ -27,18 +26,12 @@ const seoLimits = {
|
|
|
27
26
|
description: 255
|
|
28
27
|
}
|
|
29
28
|
|
|
30
|
-
type TMetasList = ({ $: string } & { [key: string]: string })[]
|
|
31
|
-
|
|
32
29
|
/*----------------------------------
|
|
33
30
|
- FONCTION
|
|
34
31
|
----------------------------------*/
|
|
35
32
|
|
|
36
33
|
export default class Page<TRouter extends Router = Router> extends PageResponse<TRouter> {
|
|
37
34
|
|
|
38
|
-
public head: TMetasList = [];
|
|
39
|
-
public metas: {[name: string]: string} = {};
|
|
40
|
-
public jsonld: Thing[] = [];
|
|
41
|
-
|
|
42
35
|
public constructor(
|
|
43
36
|
public route: TRoute | TErrorRoute,
|
|
44
37
|
public renderer: TFrontRenderer,
|