create-vite-hyperapp 1.2.0 → 2.0.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 +110 -18
- package/create-vite-hyperapp.mjs +193 -0
- package/package.json +18 -11
- package/templates/{template → common}/_gitignore +1 -1
- package/templates/{template-ts/src → common/src/app}/style.css +0 -4
- package/templates/{template → js-html-cli}/index.html +3 -3
- package/templates/js-html-cli/jsconfig.json +13 -0
- package/templates/js-html-cli/package.json +20 -0
- package/templates/js-html-cli/src/app/counter.js +5 -0
- package/templates/js-html-cli/src/app/logos.js +24 -0
- package/templates/js-html-cli/src/app/main.js +24 -0
- package/templates/{template → js-html-cli}/src/run.js +2 -2
- package/templates/js-html-cli/vite.config.js +12 -0
- package/templates/{template-ssr → js-html-ssr}/index.html +2 -2
- package/templates/js-html-ssr/jsconfig.json +13 -0
- package/templates/js-html-ssr/package.json +25 -0
- package/templates/{template-ssr → js-html-ssr}/server.js +10 -8
- package/templates/js-html-ssr/src/app/counter.js +5 -0
- package/templates/js-html-ssr/src/app/logos.js +24 -0
- package/templates/js-html-ssr/src/app/main.js +24 -0
- package/templates/{template-ssr → js-html-ssr}/src/entry-client.js +2 -2
- package/templates/js-html-ssr/src/entry-server.js +5 -0
- package/templates/js-html-ssr/vite.config.js +13 -0
- package/templates/js-jsx-cli/index.html +13 -0
- package/templates/js-jsx-cli/jsconfig.json +15 -0
- package/templates/{template → js-jsx-cli}/package.json +3 -3
- package/templates/js-jsx-cli/src/app/logos.jsx +15 -0
- package/templates/{template/src → js-jsx-cli/src/app}/main.jsx +1 -13
- package/templates/js-jsx-cli/src/run.js +5 -0
- package/templates/js-jsx-cli/vite.config.js +12 -0
- package/templates/js-jsx-ssr/index.html +13 -0
- package/templates/js-jsx-ssr/jsconfig.json +15 -0
- package/templates/{template-ssr → js-jsx-ssr}/package.json +7 -7
- package/templates/{template-ts-ssr → js-jsx-ssr}/server.js +11 -9
- package/templates/js-jsx-ssr/src/app/logos.jsx +15 -0
- package/templates/{template-ssr/src → js-jsx-ssr/src/app}/main.jsx +1 -13
- package/templates/js-jsx-ssr/src/entry-client.js +5 -0
- package/templates/js-jsx-ssr/src/entry-server.js +5 -0
- package/templates/js-jsx-ssr/vite.config.js +13 -0
- package/templates/js-plain-cli/index.html +13 -0
- package/templates/js-plain-cli/jsconfig.json +13 -0
- package/templates/{template-ts → js-plain-cli}/package.json +4 -5
- package/templates/js-plain-cli/src/app/counter.js +8 -0
- package/templates/js-plain-cli/src/app/logos.js +18 -0
- package/templates/js-plain-cli/src/app/main.js +25 -0
- package/templates/js-plain-cli/src/run.js +5 -0
- package/templates/js-plain-cli/vite.config.js +12 -0
- package/templates/js-plain-ssr/index.html +13 -0
- package/templates/js-plain-ssr/jsconfig.json +13 -0
- package/templates/{template-ts-ssr → js-plain-ssr}/package.json +8 -9
- package/templates/js-plain-ssr/server.js +62 -0
- package/templates/js-plain-ssr/src/app/counter.js +8 -0
- package/templates/js-plain-ssr/src/app/logos.js +18 -0
- package/templates/js-plain-ssr/src/app/main.js +25 -0
- package/templates/js-plain-ssr/src/entry-client.js +5 -0
- package/templates/js-plain-ssr/src/entry-server.js +5 -0
- package/templates/js-plain-ssr/vite.config.js +13 -0
- package/templates/tj-html-cli/index.html +13 -0
- package/templates/tj-html-cli/jsconfig.json +29 -0
- package/templates/tj-html-cli/package.json +21 -0
- package/templates/tj-html-cli/src/app/counter.js +16 -0
- package/templates/tj-html-cli/src/app/logos.js +24 -0
- package/templates/tj-html-cli/src/app/main.js +27 -0
- package/templates/tj-html-cli/src/run.js +5 -0
- package/templates/tj-html-cli/src/types/global.d.ts +13 -0
- package/templates/tj-html-cli/src/types/hyperapp-html.d.ts +101 -0
- package/templates/tj-html-cli/src/types/hyperapp-svg.d.ts +73 -0
- package/templates/tj-html-cli/src/types/hyperapp-tags.d.ts +34 -0
- package/templates/tj-html-cli/vite.config.js +12 -0
- package/templates/tj-html-ssr/index.html +13 -0
- package/templates/tj-html-ssr/jsconfig.json +31 -0
- package/templates/tj-html-ssr/package.json +29 -0
- package/templates/tj-html-ssr/server.js +63 -0
- package/templates/tj-html-ssr/src/app/counter.js +16 -0
- package/templates/tj-html-ssr/src/app/logos.js +24 -0
- package/templates/tj-html-ssr/src/app/main.js +27 -0
- package/templates/tj-html-ssr/src/entry-client.js +5 -0
- package/templates/tj-html-ssr/src/entry-server.js +5 -0
- package/templates/tj-html-ssr/src/types/global.d.ts +13 -0
- package/templates/tj-html-ssr/src/types/hyperapp-html.d.ts +101 -0
- package/templates/tj-html-ssr/src/types/hyperapp-svg.d.ts +73 -0
- package/templates/tj-html-ssr/src/types/hyperapp-tags.d.ts +34 -0
- package/templates/tj-html-ssr/vite.config.js +13 -0
- package/templates/tj-jsx-cli/index.html +13 -0
- package/templates/tj-jsx-cli/jsconfig.json +31 -0
- package/templates/tj-jsx-cli/package.json +19 -0
- package/templates/tj-jsx-cli/src/app/counter.jsx +18 -0
- package/templates/tj-jsx-cli/src/app/logos.jsx +15 -0
- package/templates/tj-jsx-cli/src/app/main.jsx +26 -0
- package/templates/tj-jsx-cli/src/run.js +5 -0
- package/templates/tj-jsx-cli/src/types/global.d.ts +13 -0
- package/templates/tj-jsx-cli/vite.config.js +12 -0
- package/templates/tj-jsx-ssr/index.html +13 -0
- package/templates/tj-jsx-ssr/jsconfig.json +33 -0
- package/templates/tj-jsx-ssr/package.json +27 -0
- package/templates/tj-jsx-ssr/server.js +63 -0
- package/templates/tj-jsx-ssr/src/app/counter.jsx +18 -0
- package/templates/tj-jsx-ssr/src/app/logos.jsx +15 -0
- package/templates/tj-jsx-ssr/src/app/main.jsx +26 -0
- package/templates/tj-jsx-ssr/src/entry-client.js +5 -0
- package/templates/tj-jsx-ssr/src/entry-server.js +5 -0
- package/templates/tj-jsx-ssr/src/types/global.d.ts +13 -0
- package/templates/tj-jsx-ssr/vite.config.js +13 -0
- package/templates/tj-plain-cli/index.html +13 -0
- package/templates/tj-plain-cli/jsconfig.json +29 -0
- package/templates/tj-plain-cli/package.json +19 -0
- package/templates/tj-plain-cli/src/app/counter.js +19 -0
- package/templates/tj-plain-cli/src/app/logos.js +18 -0
- package/templates/tj-plain-cli/src/app/main.js +28 -0
- package/templates/tj-plain-cli/src/run.js +5 -0
- package/templates/tj-plain-cli/src/types/global.d.ts +13 -0
- package/templates/tj-plain-cli/src/types/hyperapp-h.d.ts +37 -0
- package/templates/tj-plain-cli/vite.config.js +12 -0
- package/templates/tj-plain-ssr/index.html +13 -0
- package/templates/tj-plain-ssr/jsconfig.json +31 -0
- package/templates/tj-plain-ssr/package.json +27 -0
- package/templates/tj-plain-ssr/server.js +63 -0
- package/templates/tj-plain-ssr/src/app/counter.js +19 -0
- package/templates/tj-plain-ssr/src/app/logos.js +18 -0
- package/templates/tj-plain-ssr/src/app/main.js +28 -0
- package/templates/tj-plain-ssr/src/entry-client.js +5 -0
- package/templates/tj-plain-ssr/src/entry-server.js +5 -0
- package/templates/tj-plain-ssr/src/types/global.d.ts +13 -0
- package/templates/tj-plain-ssr/src/types/hyperapp-h.d.ts +37 -0
- package/templates/tj-plain-ssr/vite.config.js +13 -0
- package/templates/{template-ts → ts-html-cli}/index.html +3 -3
- package/templates/ts-html-cli/package.json +21 -0
- package/templates/ts-html-cli/src/app/counter.ts +12 -0
- package/templates/ts-html-cli/src/app/logos.ts +33 -0
- package/templates/ts-html-cli/src/app/main.ts +27 -0
- package/templates/{template-ts → ts-html-cli}/src/run.ts +2 -2
- package/templates/ts-html-cli/src/types/hyperapp-html.d.ts +101 -0
- package/templates/ts-html-cli/src/types/hyperapp-svg.d.ts +73 -0
- package/templates/ts-html-cli/src/types/hyperapp-tags.d.ts +34 -0
- package/templates/ts-html-cli/tsconfig.json +27 -0
- package/templates/ts-html-cli/vite.config.ts +12 -0
- package/templates/{template-ts-ssr → ts-html-ssr}/index.html +2 -2
- package/templates/ts-html-ssr/package.json +32 -0
- package/templates/ts-html-ssr/server.ts +63 -0
- package/templates/ts-html-ssr/src/app/counter.ts +12 -0
- package/templates/ts-html-ssr/src/app/logos.ts +33 -0
- package/templates/ts-html-ssr/src/app/main.ts +27 -0
- package/templates/{template-ts-ssr → ts-html-ssr}/src/entry-client.ts +2 -2
- package/templates/ts-html-ssr/src/entry-server.ts +5 -0
- package/templates/ts-html-ssr/src/types/hyperapp-html.d.ts +101 -0
- package/templates/ts-html-ssr/src/types/hyperapp-svg.d.ts +73 -0
- package/templates/ts-html-ssr/src/types/hyperapp-tags.d.ts +34 -0
- package/templates/ts-html-ssr/tsconfig.json +27 -0
- package/templates/ts-html-ssr/vite.config.ts +13 -0
- package/templates/ts-jsx-cli/index.html +13 -0
- package/templates/ts-jsx-cli/package.json +21 -0
- package/templates/{template-ts-ssr/src → ts-jsx-cli/src/app}/counter.tsx +3 -3
- package/templates/ts-jsx-cli/src/app/logos.tsx +19 -0
- package/templates/ts-jsx-cli/src/app/main.tsx +26 -0
- package/templates/ts-jsx-cli/src/assets/typescript.svg +1 -0
- package/templates/ts-jsx-cli/src/run.ts +5 -0
- package/templates/{template-ts → ts-jsx-cli}/tsconfig.json +6 -3
- package/templates/ts-jsx-cli/vite.config.ts +12 -0
- package/templates/ts-jsx-ssr/index.html +13 -0
- package/templates/ts-jsx-ssr/package.json +30 -0
- package/templates/ts-jsx-ssr/server.ts +63 -0
- package/templates/{template-ts/src → ts-jsx-ssr/src/app}/counter.tsx +3 -3
- package/templates/ts-jsx-ssr/src/app/logos.tsx +19 -0
- package/templates/{template-ts-ssr/src → ts-jsx-ssr/src/app}/main.tsx +1 -17
- package/templates/ts-jsx-ssr/src/assets/typescript.svg +1 -0
- package/templates/ts-jsx-ssr/src/entry-client.ts +5 -0
- package/templates/ts-jsx-ssr/src/entry-server.ts +5 -0
- package/templates/{template-ts-ssr → ts-jsx-ssr}/tsconfig.json +7 -4
- package/templates/ts-jsx-ssr/vite.config.ts +13 -0
- package/templates/ts-plain-cli/index.html +13 -0
- package/templates/ts-plain-cli/package.json +21 -0
- package/templates/ts-plain-cli/src/app/counter.ts +13 -0
- package/templates/ts-plain-cli/src/app/logos.ts +30 -0
- package/templates/ts-plain-cli/src/app/main.ts +27 -0
- package/templates/ts-plain-cli/src/assets/typescript.svg +1 -0
- package/templates/ts-plain-cli/src/run.ts +5 -0
- package/templates/ts-plain-cli/src/types/hyperapp-h.d.ts +37 -0
- package/templates/ts-plain-cli/tsconfig.json +27 -0
- package/templates/ts-plain-cli/vite.config.ts +12 -0
- package/templates/ts-plain-ssr/index.html +13 -0
- package/templates/ts-plain-ssr/package.json +30 -0
- package/templates/ts-plain-ssr/server.ts +63 -0
- package/templates/ts-plain-ssr/src/app/counter.ts +13 -0
- package/templates/ts-plain-ssr/src/app/logos.ts +30 -0
- package/templates/ts-plain-ssr/src/app/main.ts +27 -0
- package/templates/ts-plain-ssr/src/assets/typescript.svg +1 -0
- package/templates/ts-plain-ssr/src/entry-client.ts +5 -0
- package/templates/ts-plain-ssr/src/entry-server.ts +5 -0
- package/templates/ts-plain-ssr/src/types/hyperapp-h.d.ts +37 -0
- package/templates/ts-plain-ssr/tsconfig.json +27 -0
- package/templates/ts-plain-ssr/vite.config.ts +13 -0
- package/index.js +0 -154
- package/templates/template/public/vite.svg +0 -1
- package/templates/template/src/hyperapp.svg +0 -4
- package/templates/template/src/style.css +0 -97
- package/templates/template/vite.config.js +0 -6
- package/templates/template-ssr/_gitignore +0 -24
- package/templates/template-ssr/src/entry-server.js +0 -5
- package/templates/template-ssr/src/style.css +0 -97
- package/templates/template-ssr/vite.config.js +0 -6
- package/templates/template-ts/_gitignore +0 -24
- package/templates/template-ts/public/vite.svg +0 -1
- package/templates/template-ts/src/hyperapp.svg +0 -4
- package/templates/template-ts/src/main.tsx +0 -42
- package/templates/template-ts/src/vite-env.d.ts +0 -2
- package/templates/template-ts/vite.config.ts +0 -6
- package/templates/template-ts-ssr/_gitignore +0 -24
- package/templates/template-ts-ssr/public/vite.svg +0 -1
- package/templates/template-ts-ssr/src/entry-server.ts +0 -5
- package/templates/template-ts-ssr/src/style.css +0 -97
- package/templates/template-ts-ssr/src/vite-env.d.ts +0 -2
- package/templates/template-ts-ssr/vite.config.ts +0 -6
- /package/templates/{template-ssr/src/hyperapp.svg → common/public/favicon.svg} +0 -0
- /package/templates/{template-ts-ssr/src → common/src/assets}/hyperapp.svg +0 -0
- /package/templates/{template-ssr/public → common/src/assets}/vite.svg +0 -0
- /package/templates/{template-ssr/src → js-jsx-cli/src/app}/counter.jsx +0 -0
- /package/templates/{template/src → js-jsx-ssr/src/app}/counter.jsx +0 -0
- /package/templates/{template-ts-ssr/src → ts-html-cli/src/assets}/typescript.svg +0 -0
- /package/templates/{template-ts/src → ts-html-ssr/src/assets}/typescript.svg +0 -0
|
@@ -0,0 +1,101 @@
|
|
|
1
|
+
declare module "@hyperapp/html" {
|
|
2
|
+
export const a: HyperappHtmlTag
|
|
3
|
+
export const b: HyperappHtmlTag
|
|
4
|
+
export const i: HyperappHtmlTag
|
|
5
|
+
export const p: HyperappHtmlTag
|
|
6
|
+
export const q: HyperappHtmlTag
|
|
7
|
+
export const s: HyperappHtmlTag
|
|
8
|
+
export const br: HyperappHtmlTag
|
|
9
|
+
export const dd: HyperappHtmlTag
|
|
10
|
+
export const dl: HyperappHtmlTag
|
|
11
|
+
export const dt: HyperappHtmlTag
|
|
12
|
+
export const em: HyperappHtmlTag
|
|
13
|
+
export const h1: HyperappHtmlTag
|
|
14
|
+
export const h2: HyperappHtmlTag
|
|
15
|
+
export const h3: HyperappHtmlTag
|
|
16
|
+
export const h4: HyperappHtmlTag
|
|
17
|
+
export const h5: HyperappHtmlTag
|
|
18
|
+
export const h6: HyperappHtmlTag
|
|
19
|
+
export const hr: HyperappHtmlTag
|
|
20
|
+
export const li: HyperappHtmlTag
|
|
21
|
+
export const ol: HyperappHtmlTag
|
|
22
|
+
export const rp: HyperappHtmlTag
|
|
23
|
+
export const rt: HyperappHtmlTag
|
|
24
|
+
export const td: HyperappHtmlTag
|
|
25
|
+
export const th: HyperappHtmlTag
|
|
26
|
+
export const tr: HyperappHtmlTag
|
|
27
|
+
export const ul: HyperappHtmlTag
|
|
28
|
+
export const bdi: HyperappHtmlTag
|
|
29
|
+
export const bdo: HyperappHtmlTag
|
|
30
|
+
export const col: HyperappHtmlTag
|
|
31
|
+
export const del: HyperappHtmlTag
|
|
32
|
+
export const dfn: HyperappHtmlTag
|
|
33
|
+
export const div: HyperappHtmlTag
|
|
34
|
+
export const img: HyperappHtmlTag
|
|
35
|
+
export const ins: HyperappHtmlTag
|
|
36
|
+
export const kbd: HyperappHtmlTag
|
|
37
|
+
export const map: HyperappHtmlTag
|
|
38
|
+
export const nav: HyperappHtmlTag
|
|
39
|
+
export const pre: HyperappHtmlTag
|
|
40
|
+
export const rtc: HyperappHtmlTag
|
|
41
|
+
export const sub: HyperappHtmlTag
|
|
42
|
+
export const sup: HyperappHtmlTag
|
|
43
|
+
export const wbr: HyperappHtmlTag
|
|
44
|
+
export const abbr: HyperappHtmlTag
|
|
45
|
+
export const area: HyperappHtmlTag
|
|
46
|
+
export const cite: HyperappHtmlTag
|
|
47
|
+
export const code: HyperappHtmlTag
|
|
48
|
+
export const data: HyperappHtmlTag
|
|
49
|
+
export const form: HyperappHtmlTag
|
|
50
|
+
export const main: HyperappHtmlTag
|
|
51
|
+
export const mark: HyperappHtmlTag
|
|
52
|
+
export const ruby: HyperappHtmlTag
|
|
53
|
+
export const samp: HyperappHtmlTag
|
|
54
|
+
export const span: HyperappHtmlTag
|
|
55
|
+
export const time: HyperappHtmlTag
|
|
56
|
+
export const aside: HyperappHtmlTag
|
|
57
|
+
export const audio: HyperappHtmlTag
|
|
58
|
+
export const input: HyperappHtmlTag
|
|
59
|
+
export const label: HyperappHtmlTag
|
|
60
|
+
export const meter: HyperappHtmlTag
|
|
61
|
+
export const param: HyperappHtmlTag
|
|
62
|
+
export const small: HyperappHtmlTag
|
|
63
|
+
export const table: HyperappHtmlTag
|
|
64
|
+
export const tbody: HyperappHtmlTag
|
|
65
|
+
export const tfoot: HyperappHtmlTag
|
|
66
|
+
export const thead: HyperappHtmlTag
|
|
67
|
+
export const track: HyperappHtmlTag
|
|
68
|
+
export const video: HyperappHtmlTag
|
|
69
|
+
export const button: HyperappHtmlTag
|
|
70
|
+
export const canvas: HyperappHtmlTag
|
|
71
|
+
export const dialog: HyperappHtmlTag
|
|
72
|
+
export const figure: HyperappHtmlTag
|
|
73
|
+
export const footer: HyperappHtmlTag
|
|
74
|
+
export const header: HyperappHtmlTag
|
|
75
|
+
export const iframe: HyperappHtmlTag
|
|
76
|
+
export const legend: HyperappHtmlTag
|
|
77
|
+
export const object: HyperappHtmlTag
|
|
78
|
+
export const option: HyperappHtmlTag
|
|
79
|
+
export const output: HyperappHtmlTag
|
|
80
|
+
export const select: HyperappHtmlTag
|
|
81
|
+
export const source: HyperappHtmlTag
|
|
82
|
+
export const strong: HyperappHtmlTag
|
|
83
|
+
export const address: HyperappHtmlTag
|
|
84
|
+
export const article: HyperappHtmlTag
|
|
85
|
+
export const caption: HyperappHtmlTag
|
|
86
|
+
export const details: HyperappHtmlTag
|
|
87
|
+
export const section: HyperappHtmlTag
|
|
88
|
+
export const summary: HyperappHtmlTag
|
|
89
|
+
export const picture: HyperappHtmlTag
|
|
90
|
+
export const colgroup: HyperappHtmlTag
|
|
91
|
+
export const datalist: HyperappHtmlTag
|
|
92
|
+
export const fieldset: HyperappHtmlTag
|
|
93
|
+
export const menuitem: HyperappHtmlTag
|
|
94
|
+
export const optgroup: HyperappHtmlTag
|
|
95
|
+
export const progress: HyperappHtmlTag
|
|
96
|
+
export const textarea: HyperappHtmlTag
|
|
97
|
+
export const blockquote: HyperappHtmlTag
|
|
98
|
+
export const figcaption: HyperappHtmlTag
|
|
99
|
+
|
|
100
|
+
export { text } from "hyperapp"
|
|
101
|
+
}
|
|
@@ -0,0 +1,73 @@
|
|
|
1
|
+
declare module "@hyperapp/svg" {
|
|
2
|
+
export const a: HyperappTag
|
|
3
|
+
export const g: HyperappTag
|
|
4
|
+
export const svg: HyperappTag
|
|
5
|
+
export const use: HyperappTag
|
|
6
|
+
export const set: HyperappTag
|
|
7
|
+
export const line: HyperappTag
|
|
8
|
+
export const path: HyperappTag
|
|
9
|
+
export const rect: HyperappTag
|
|
10
|
+
export const desc: HyperappTag
|
|
11
|
+
export const defs: HyperappTag
|
|
12
|
+
export const mask: HyperappTag
|
|
13
|
+
export const tref: HyperappTag
|
|
14
|
+
export const font: HyperappTag
|
|
15
|
+
export const stop: HyperappTag
|
|
16
|
+
export const view: HyperappTag
|
|
17
|
+
export const text_: HyperappTag
|
|
18
|
+
export const image: HyperappTag
|
|
19
|
+
export const mpath: HyperappTag
|
|
20
|
+
export const title: HyperappTag
|
|
21
|
+
export const glyph: HyperappTag
|
|
22
|
+
export const tspan: HyperappTag
|
|
23
|
+
export const style: HyperappTag
|
|
24
|
+
export const circle: HyperappTag
|
|
25
|
+
export const marker: HyperappTag
|
|
26
|
+
export const symbol: HyperappTag
|
|
27
|
+
export const feTile: HyperappTag
|
|
28
|
+
export const cursor: HyperappTag
|
|
29
|
+
export const filter: HyperappTag
|
|
30
|
+
export const switch_: HyperappTag
|
|
31
|
+
export const ellipse: HyperappTag
|
|
32
|
+
export const polygon: HyperappTag
|
|
33
|
+
export const animate: HyperappTag
|
|
34
|
+
export const pattern: HyperappTag
|
|
35
|
+
export const feBlend: HyperappTag
|
|
36
|
+
export const feFlood: HyperappTag
|
|
37
|
+
export const feFuncA: HyperappTag
|
|
38
|
+
export const feFuncB: HyperappTag
|
|
39
|
+
export const feFuncG: HyperappTag
|
|
40
|
+
export const feFuncR: HyperappTag
|
|
41
|
+
export const feImage: HyperappTag
|
|
42
|
+
export const feMerge: HyperappTag
|
|
43
|
+
export const polyline: HyperappTag
|
|
44
|
+
export const metadata: HyperappTag
|
|
45
|
+
export const altGlyph: HyperappTag
|
|
46
|
+
export const glyphRef: HyperappTag
|
|
47
|
+
export const textPath: HyperappTag
|
|
48
|
+
export const feOffset: HyperappTag
|
|
49
|
+
export const clipPath: HyperappTag
|
|
50
|
+
export const altGlyphDef: HyperappTag
|
|
51
|
+
export const feComposite: HyperappTag
|
|
52
|
+
export const feMergeNode: HyperappTag
|
|
53
|
+
export const feSpotLight: HyperappTag
|
|
54
|
+
export const animateColor: HyperappTag
|
|
55
|
+
export const altGlyphItem: HyperappTag
|
|
56
|
+
export const feMorphology: HyperappTag
|
|
57
|
+
export const feTurbulence: HyperappTag
|
|
58
|
+
export const fePointLight: HyperappTag
|
|
59
|
+
export const colorProfile: HyperappTag
|
|
60
|
+
export const foreignObject: HyperappTag
|
|
61
|
+
export const animateMotion: HyperappTag
|
|
62
|
+
export const feColorMatrix: HyperappTag
|
|
63
|
+
export const linearGradient: HyperappTag
|
|
64
|
+
export const radialGradient: HyperappTag
|
|
65
|
+
export const feGaussianBlur: HyperappTag
|
|
66
|
+
export const feDistantLight: HyperappTag
|
|
67
|
+
export const animateTransform: HyperappTag
|
|
68
|
+
export const feConvolveMatrix: HyperappTag
|
|
69
|
+
export const feDiffuseLighting: HyperappTag
|
|
70
|
+
export const feDisplacementMap: HyperappTag
|
|
71
|
+
export const feSpecularLighting: HyperappTag
|
|
72
|
+
export const feComponentTransfer: HyperappTag
|
|
73
|
+
}
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
// An action-free tree can be embedded in an app with any state type.
|
|
2
|
+
type PassiveProps = import("hyperapp").Props<any> & {
|
|
3
|
+
[K in keyof import("hyperapp").EventActions<any>]?: never
|
|
4
|
+
}
|
|
5
|
+
|
|
6
|
+
type PassiveChild = boolean | null | undefined | import("hyperapp").TextVNode | PassiveVNode
|
|
7
|
+
type PassiveChildren = PassiveChild | readonly PassiveChild[]
|
|
8
|
+
|
|
9
|
+
type PassiveVNode = Omit<
|
|
10
|
+
import("hyperapp").ElementVNode<any>,
|
|
11
|
+
"props" | "children" | "events" | "tag" | "memo"
|
|
12
|
+
> & {
|
|
13
|
+
readonly props: PassiveProps
|
|
14
|
+
readonly children: readonly PassiveChild[]
|
|
15
|
+
readonly tag: string
|
|
16
|
+
events?: never
|
|
17
|
+
memo?: never
|
|
18
|
+
}
|
|
19
|
+
|
|
20
|
+
type HyperappChildren<S> =
|
|
21
|
+
| import("hyperapp").MaybeVNode<S>
|
|
22
|
+
| PassiveChild
|
|
23
|
+
| readonly (import("hyperapp").MaybeVNode<S> | PassiveChild)[]
|
|
24
|
+
|
|
25
|
+
interface HyperappTag {
|
|
26
|
+
(props: PassiveProps, children?: PassiveChildren): PassiveVNode
|
|
27
|
+
(children: PassiveChildren): PassiveVNode
|
|
28
|
+
<S>(props: import("hyperapp").Props<S>, children?: HyperappChildren<S>): import("hyperapp").ElementVNode<S>
|
|
29
|
+
<S>(children: import("hyperapp").VNode<S> | readonly (import("hyperapp").MaybeVNode<S> | PassiveChild)[]): import("hyperapp").ElementVNode<S>
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
interface HyperappHtmlTag extends HyperappTag {
|
|
33
|
+
(): PassiveVNode
|
|
34
|
+
}
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
{
|
|
2
|
+
"compilerOptions": {
|
|
3
|
+
"target": "ES2020",
|
|
4
|
+
"useDefineForClassFields": true,
|
|
5
|
+
"module": "ESNext",
|
|
6
|
+
"lib": ["ES2020", "DOM", "DOM.Iterable"],
|
|
7
|
+
"types": ["vite/client"],
|
|
8
|
+
"skipLibCheck": true,
|
|
9
|
+
|
|
10
|
+
/* Bundler mode */
|
|
11
|
+
"moduleResolution": "bundler",
|
|
12
|
+
"paths": {
|
|
13
|
+
"@/*": ["./src/*"]
|
|
14
|
+
},
|
|
15
|
+
"allowImportingTsExtensions": true,
|
|
16
|
+
"resolveJsonModule": true,
|
|
17
|
+
"isolatedModules": true,
|
|
18
|
+
"noEmit": true,
|
|
19
|
+
|
|
20
|
+
/* Linting */
|
|
21
|
+
"strict": true,
|
|
22
|
+
"noUnusedLocals": true,
|
|
23
|
+
"noUnusedParameters": true,
|
|
24
|
+
"noFallthroughCasesInSwitch": true
|
|
25
|
+
},
|
|
26
|
+
"include": ["src"]
|
|
27
|
+
}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { defineConfig } from "vite"
|
|
2
|
+
import hyperapp from "vite-plugin-hyperapp"
|
|
3
|
+
import { fileURLToPath } from "node:url"
|
|
4
|
+
|
|
5
|
+
export default defineConfig({
|
|
6
|
+
plugins: [hyperapp()],
|
|
7
|
+
resolve: {
|
|
8
|
+
alias: {
|
|
9
|
+
"@": fileURLToPath(new URL("./src", import.meta.url)),
|
|
10
|
+
},
|
|
11
|
+
},
|
|
12
|
+
})
|
|
@@ -2,9 +2,9 @@
|
|
|
2
2
|
<html lang="en">
|
|
3
3
|
<head>
|
|
4
4
|
<meta charset="UTF-8" />
|
|
5
|
-
<link rel="icon" type="image/svg+xml" href="/
|
|
5
|
+
<link rel="icon" type="image/svg+xml" href="/favicon.svg" />
|
|
6
6
|
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
|
7
|
-
<title>
|
|
7
|
+
<title>__PROJECTNAME__</title>
|
|
8
8
|
</head>
|
|
9
9
|
<body>
|
|
10
10
|
<!--ssr-outlet-->
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "__PROJECTNAME__",
|
|
3
|
+
"private": true,
|
|
4
|
+
"version": "0.0.0",
|
|
5
|
+
"type": "module",
|
|
6
|
+
"scripts": {
|
|
7
|
+
"dev": "node server.ts",
|
|
8
|
+
"build:client": "vite build --outDir dist/client",
|
|
9
|
+
"build:server": "vite build --outDir dist/server --ssr src/entry-server.ts",
|
|
10
|
+
"build": "tsc && npm run build:client && npm run build:server",
|
|
11
|
+
"preview": "NODE_ENV=production node server.ts"
|
|
12
|
+
},
|
|
13
|
+
"engines": {
|
|
14
|
+
"node": ">=22.18.0"
|
|
15
|
+
},
|
|
16
|
+
"devDependencies": {
|
|
17
|
+
"@types/compression": "^1.8.1",
|
|
18
|
+
"@types/express": "^4.17.25",
|
|
19
|
+
"@types/node": "^22.20.5",
|
|
20
|
+
"typescript": "^7.0.2",
|
|
21
|
+
"vite": "^8.3.4"
|
|
22
|
+
},
|
|
23
|
+
"dependencies": {
|
|
24
|
+
"@hyperapp/html": "^2.0.0",
|
|
25
|
+
"@hyperapp/svg": "^2.0.0",
|
|
26
|
+
"compression": "^1.7.4",
|
|
27
|
+
"express": "^4.19.2",
|
|
28
|
+
"hyperapp": "^2.0.22",
|
|
29
|
+
"sirv": "^2.0.4",
|
|
30
|
+
"vite-plugin-hyperapp": "^2.0.1"
|
|
31
|
+
}
|
|
32
|
+
}
|
|
@@ -0,0 +1,63 @@
|
|
|
1
|
+
/*
|
|
2
|
+
---------------------------------
|
|
3
|
+
Cribbed to large extent from template-ssr-solid/server.js
|
|
4
|
+
---------------------------------
|
|
5
|
+
*/
|
|
6
|
+
import fs from "node:fs/promises"
|
|
7
|
+
import express from "express"
|
|
8
|
+
import type { ViteDevServer } from "vite"
|
|
9
|
+
|
|
10
|
+
const isProduction = process.env.NODE_ENV === "production"
|
|
11
|
+
const port = process.env.PORT || 5173
|
|
12
|
+
const base = process.env.BASE || "/"
|
|
13
|
+
|
|
14
|
+
async function createServer() {
|
|
15
|
+
const app = express()
|
|
16
|
+
|
|
17
|
+
let vite: ViteDevServer | undefined
|
|
18
|
+
if (!isProduction) {
|
|
19
|
+
const { createServer } = await import("vite")
|
|
20
|
+
vite = await createServer({
|
|
21
|
+
server: { middlewareMode: true },
|
|
22
|
+
appType: "custom",
|
|
23
|
+
})
|
|
24
|
+
app.use(vite.middlewares)
|
|
25
|
+
} else {
|
|
26
|
+
const compression = (await import("compression")).default
|
|
27
|
+
const sirv = (await import("sirv")).default
|
|
28
|
+
app.use(compression())
|
|
29
|
+
app.use(base, sirv("./dist/client", { extensions: [] }))
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
app.use("*", async (req, res, next) => {
|
|
33
|
+
const url = req.originalUrl
|
|
34
|
+
if (!url.startsWith(base)) return next()
|
|
35
|
+
try {
|
|
36
|
+
let template
|
|
37
|
+
let render: () => string
|
|
38
|
+
if (!isProduction) {
|
|
39
|
+
if (!vite) throw new Error("Vite dev server is not initialized")
|
|
40
|
+
// Always read fresh template in development
|
|
41
|
+
template = await fs.readFile("./index.html", "utf-8")
|
|
42
|
+
template = await vite.transformIndexHtml(url, template)
|
|
43
|
+
render = (await vite.ssrLoadModule("/src/entry-server.ts")).render
|
|
44
|
+
} else {
|
|
45
|
+
template = await fs.readFile("./dist/client/index.html", "utf-8")
|
|
46
|
+
const serverEntry = "./dist/server/entry-server.js"
|
|
47
|
+
render = (await import(serverEntry)).render
|
|
48
|
+
}
|
|
49
|
+
const html = template.replace(`<!--ssr-outlet-->`, () => render())
|
|
50
|
+
res.status(200).set({ "Content-Type": "text/html" }).end(html)
|
|
51
|
+
} catch (e) {
|
|
52
|
+
if (e instanceof Error) vite?.ssrFixStacktrace(e)
|
|
53
|
+
console.error(e)
|
|
54
|
+
res.status(500).end()
|
|
55
|
+
}
|
|
56
|
+
})
|
|
57
|
+
|
|
58
|
+
app.listen(port, () => {
|
|
59
|
+
console.log(`Server started at http://localhost:${port}`)
|
|
60
|
+
})
|
|
61
|
+
}
|
|
62
|
+
|
|
63
|
+
createServer()
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { div, button, text } from "@hyperapp/html"
|
|
2
|
+
import type { Action } from "hyperapp"
|
|
3
|
+
|
|
4
|
+
type CounterProps<S> = {
|
|
5
|
+
clicks: number
|
|
6
|
+
onclick: Action<S>
|
|
7
|
+
}
|
|
8
|
+
|
|
9
|
+
const Counter = <S>({ clicks, onclick }: CounterProps<S>) =>
|
|
10
|
+
div({ class: "card" }, button({ onclick }, text("Clicks: " + clicks)))
|
|
11
|
+
|
|
12
|
+
export default Counter
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
import { a, img } from "@hyperapp/html"
|
|
2
|
+
import viteLogo from "@/assets/vite.svg"
|
|
3
|
+
import typescriptLogo from "@/assets/typescript.svg"
|
|
4
|
+
import hyperappLogo from "@/assets/hyperapp.svg"
|
|
5
|
+
|
|
6
|
+
const Logos = () => [
|
|
7
|
+
a(
|
|
8
|
+
{ href: "https://vitejs.dev" },
|
|
9
|
+
img({
|
|
10
|
+
src: viteLogo,
|
|
11
|
+
class: "logo",
|
|
12
|
+
alt: "Vite logo",
|
|
13
|
+
}),
|
|
14
|
+
),
|
|
15
|
+
a(
|
|
16
|
+
{ href: "https://github.com/jorgebucaran/hyperapp" },
|
|
17
|
+
img({
|
|
18
|
+
src: hyperappLogo,
|
|
19
|
+
class: "logo",
|
|
20
|
+
alt: "Hyperapp logo",
|
|
21
|
+
}),
|
|
22
|
+
),
|
|
23
|
+
a(
|
|
24
|
+
{ href: "https://www.typescriptlang.org/" },
|
|
25
|
+
img({
|
|
26
|
+
src: typescriptLogo,
|
|
27
|
+
class: "logo",
|
|
28
|
+
alt: "TypeScript logo",
|
|
29
|
+
}),
|
|
30
|
+
),
|
|
31
|
+
]
|
|
32
|
+
|
|
33
|
+
export default Logos
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import "./style.css"
|
|
2
|
+
import type { Action } from "hyperapp"
|
|
3
|
+
import { main, h1, p, text } from "@hyperapp/html"
|
|
4
|
+
import Counter from "./counter"
|
|
5
|
+
import Logos from "./logos"
|
|
6
|
+
|
|
7
|
+
type State = { counter: number }
|
|
8
|
+
|
|
9
|
+
export const init: Action<State> = () => ({
|
|
10
|
+
counter: 0,
|
|
11
|
+
})
|
|
12
|
+
|
|
13
|
+
const HandleClick: Action<State> = state => ({
|
|
14
|
+
...state,
|
|
15
|
+
counter: state.counter + 1,
|
|
16
|
+
})
|
|
17
|
+
|
|
18
|
+
export const view = (state: State) =>
|
|
19
|
+
main({ id: "app" }, [
|
|
20
|
+
h1(text("Vite (SSR) + Hyperapp + TypeScript")),
|
|
21
|
+
...Logos(),
|
|
22
|
+
Counter({ clicks: state.counter, onclick: HandleClick }),
|
|
23
|
+
p(
|
|
24
|
+
{ class: "read-the-docs" },
|
|
25
|
+
text("Click on the Vite, Hyperapp & TypeScript logos to learn more"),
|
|
26
|
+
),
|
|
27
|
+
])
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { app } from "hyperapp"
|
|
2
|
-
import { init, view } from "./main"
|
|
2
|
+
import { init, view } from "./app/main"
|
|
3
3
|
const node = document.querySelector("#app")
|
|
4
4
|
if (!node) throw new Error("mountpoint not found")
|
|
5
|
-
|
|
5
|
+
app({ init, view, node })
|
|
@@ -0,0 +1,101 @@
|
|
|
1
|
+
declare module "@hyperapp/html" {
|
|
2
|
+
export const a: HyperappHtmlTag
|
|
3
|
+
export const b: HyperappHtmlTag
|
|
4
|
+
export const i: HyperappHtmlTag
|
|
5
|
+
export const p: HyperappHtmlTag
|
|
6
|
+
export const q: HyperappHtmlTag
|
|
7
|
+
export const s: HyperappHtmlTag
|
|
8
|
+
export const br: HyperappHtmlTag
|
|
9
|
+
export const dd: HyperappHtmlTag
|
|
10
|
+
export const dl: HyperappHtmlTag
|
|
11
|
+
export const dt: HyperappHtmlTag
|
|
12
|
+
export const em: HyperappHtmlTag
|
|
13
|
+
export const h1: HyperappHtmlTag
|
|
14
|
+
export const h2: HyperappHtmlTag
|
|
15
|
+
export const h3: HyperappHtmlTag
|
|
16
|
+
export const h4: HyperappHtmlTag
|
|
17
|
+
export const h5: HyperappHtmlTag
|
|
18
|
+
export const h6: HyperappHtmlTag
|
|
19
|
+
export const hr: HyperappHtmlTag
|
|
20
|
+
export const li: HyperappHtmlTag
|
|
21
|
+
export const ol: HyperappHtmlTag
|
|
22
|
+
export const rp: HyperappHtmlTag
|
|
23
|
+
export const rt: HyperappHtmlTag
|
|
24
|
+
export const td: HyperappHtmlTag
|
|
25
|
+
export const th: HyperappHtmlTag
|
|
26
|
+
export const tr: HyperappHtmlTag
|
|
27
|
+
export const ul: HyperappHtmlTag
|
|
28
|
+
export const bdi: HyperappHtmlTag
|
|
29
|
+
export const bdo: HyperappHtmlTag
|
|
30
|
+
export const col: HyperappHtmlTag
|
|
31
|
+
export const del: HyperappHtmlTag
|
|
32
|
+
export const dfn: HyperappHtmlTag
|
|
33
|
+
export const div: HyperappHtmlTag
|
|
34
|
+
export const img: HyperappHtmlTag
|
|
35
|
+
export const ins: HyperappHtmlTag
|
|
36
|
+
export const kbd: HyperappHtmlTag
|
|
37
|
+
export const map: HyperappHtmlTag
|
|
38
|
+
export const nav: HyperappHtmlTag
|
|
39
|
+
export const pre: HyperappHtmlTag
|
|
40
|
+
export const rtc: HyperappHtmlTag
|
|
41
|
+
export const sub: HyperappHtmlTag
|
|
42
|
+
export const sup: HyperappHtmlTag
|
|
43
|
+
export const wbr: HyperappHtmlTag
|
|
44
|
+
export const abbr: HyperappHtmlTag
|
|
45
|
+
export const area: HyperappHtmlTag
|
|
46
|
+
export const cite: HyperappHtmlTag
|
|
47
|
+
export const code: HyperappHtmlTag
|
|
48
|
+
export const data: HyperappHtmlTag
|
|
49
|
+
export const form: HyperappHtmlTag
|
|
50
|
+
export const main: HyperappHtmlTag
|
|
51
|
+
export const mark: HyperappHtmlTag
|
|
52
|
+
export const ruby: HyperappHtmlTag
|
|
53
|
+
export const samp: HyperappHtmlTag
|
|
54
|
+
export const span: HyperappHtmlTag
|
|
55
|
+
export const time: HyperappHtmlTag
|
|
56
|
+
export const aside: HyperappHtmlTag
|
|
57
|
+
export const audio: HyperappHtmlTag
|
|
58
|
+
export const input: HyperappHtmlTag
|
|
59
|
+
export const label: HyperappHtmlTag
|
|
60
|
+
export const meter: HyperappHtmlTag
|
|
61
|
+
export const param: HyperappHtmlTag
|
|
62
|
+
export const small: HyperappHtmlTag
|
|
63
|
+
export const table: HyperappHtmlTag
|
|
64
|
+
export const tbody: HyperappHtmlTag
|
|
65
|
+
export const tfoot: HyperappHtmlTag
|
|
66
|
+
export const thead: HyperappHtmlTag
|
|
67
|
+
export const track: HyperappHtmlTag
|
|
68
|
+
export const video: HyperappHtmlTag
|
|
69
|
+
export const button: HyperappHtmlTag
|
|
70
|
+
export const canvas: HyperappHtmlTag
|
|
71
|
+
export const dialog: HyperappHtmlTag
|
|
72
|
+
export const figure: HyperappHtmlTag
|
|
73
|
+
export const footer: HyperappHtmlTag
|
|
74
|
+
export const header: HyperappHtmlTag
|
|
75
|
+
export const iframe: HyperappHtmlTag
|
|
76
|
+
export const legend: HyperappHtmlTag
|
|
77
|
+
export const object: HyperappHtmlTag
|
|
78
|
+
export const option: HyperappHtmlTag
|
|
79
|
+
export const output: HyperappHtmlTag
|
|
80
|
+
export const select: HyperappHtmlTag
|
|
81
|
+
export const source: HyperappHtmlTag
|
|
82
|
+
export const strong: HyperappHtmlTag
|
|
83
|
+
export const address: HyperappHtmlTag
|
|
84
|
+
export const article: HyperappHtmlTag
|
|
85
|
+
export const caption: HyperappHtmlTag
|
|
86
|
+
export const details: HyperappHtmlTag
|
|
87
|
+
export const section: HyperappHtmlTag
|
|
88
|
+
export const summary: HyperappHtmlTag
|
|
89
|
+
export const picture: HyperappHtmlTag
|
|
90
|
+
export const colgroup: HyperappHtmlTag
|
|
91
|
+
export const datalist: HyperappHtmlTag
|
|
92
|
+
export const fieldset: HyperappHtmlTag
|
|
93
|
+
export const menuitem: HyperappHtmlTag
|
|
94
|
+
export const optgroup: HyperappHtmlTag
|
|
95
|
+
export const progress: HyperappHtmlTag
|
|
96
|
+
export const textarea: HyperappHtmlTag
|
|
97
|
+
export const blockquote: HyperappHtmlTag
|
|
98
|
+
export const figcaption: HyperappHtmlTag
|
|
99
|
+
|
|
100
|
+
export { text } from "hyperapp"
|
|
101
|
+
}
|
|
@@ -0,0 +1,73 @@
|
|
|
1
|
+
declare module "@hyperapp/svg" {
|
|
2
|
+
export const a: HyperappTag
|
|
3
|
+
export const g: HyperappTag
|
|
4
|
+
export const svg: HyperappTag
|
|
5
|
+
export const use: HyperappTag
|
|
6
|
+
export const set: HyperappTag
|
|
7
|
+
export const line: HyperappTag
|
|
8
|
+
export const path: HyperappTag
|
|
9
|
+
export const rect: HyperappTag
|
|
10
|
+
export const desc: HyperappTag
|
|
11
|
+
export const defs: HyperappTag
|
|
12
|
+
export const mask: HyperappTag
|
|
13
|
+
export const tref: HyperappTag
|
|
14
|
+
export const font: HyperappTag
|
|
15
|
+
export const stop: HyperappTag
|
|
16
|
+
export const view: HyperappTag
|
|
17
|
+
export const text_: HyperappTag
|
|
18
|
+
export const image: HyperappTag
|
|
19
|
+
export const mpath: HyperappTag
|
|
20
|
+
export const title: HyperappTag
|
|
21
|
+
export const glyph: HyperappTag
|
|
22
|
+
export const tspan: HyperappTag
|
|
23
|
+
export const style: HyperappTag
|
|
24
|
+
export const circle: HyperappTag
|
|
25
|
+
export const marker: HyperappTag
|
|
26
|
+
export const symbol: HyperappTag
|
|
27
|
+
export const feTile: HyperappTag
|
|
28
|
+
export const cursor: HyperappTag
|
|
29
|
+
export const filter: HyperappTag
|
|
30
|
+
export const switch_: HyperappTag
|
|
31
|
+
export const ellipse: HyperappTag
|
|
32
|
+
export const polygon: HyperappTag
|
|
33
|
+
export const animate: HyperappTag
|
|
34
|
+
export const pattern: HyperappTag
|
|
35
|
+
export const feBlend: HyperappTag
|
|
36
|
+
export const feFlood: HyperappTag
|
|
37
|
+
export const feFuncA: HyperappTag
|
|
38
|
+
export const feFuncB: HyperappTag
|
|
39
|
+
export const feFuncG: HyperappTag
|
|
40
|
+
export const feFuncR: HyperappTag
|
|
41
|
+
export const feImage: HyperappTag
|
|
42
|
+
export const feMerge: HyperappTag
|
|
43
|
+
export const polyline: HyperappTag
|
|
44
|
+
export const metadata: HyperappTag
|
|
45
|
+
export const altGlyph: HyperappTag
|
|
46
|
+
export const glyphRef: HyperappTag
|
|
47
|
+
export const textPath: HyperappTag
|
|
48
|
+
export const feOffset: HyperappTag
|
|
49
|
+
export const clipPath: HyperappTag
|
|
50
|
+
export const altGlyphDef: HyperappTag
|
|
51
|
+
export const feComposite: HyperappTag
|
|
52
|
+
export const feMergeNode: HyperappTag
|
|
53
|
+
export const feSpotLight: HyperappTag
|
|
54
|
+
export const animateColor: HyperappTag
|
|
55
|
+
export const altGlyphItem: HyperappTag
|
|
56
|
+
export const feMorphology: HyperappTag
|
|
57
|
+
export const feTurbulence: HyperappTag
|
|
58
|
+
export const fePointLight: HyperappTag
|
|
59
|
+
export const colorProfile: HyperappTag
|
|
60
|
+
export const foreignObject: HyperappTag
|
|
61
|
+
export const animateMotion: HyperappTag
|
|
62
|
+
export const feColorMatrix: HyperappTag
|
|
63
|
+
export const linearGradient: HyperappTag
|
|
64
|
+
export const radialGradient: HyperappTag
|
|
65
|
+
export const feGaussianBlur: HyperappTag
|
|
66
|
+
export const feDistantLight: HyperappTag
|
|
67
|
+
export const animateTransform: HyperappTag
|
|
68
|
+
export const feConvolveMatrix: HyperappTag
|
|
69
|
+
export const feDiffuseLighting: HyperappTag
|
|
70
|
+
export const feDisplacementMap: HyperappTag
|
|
71
|
+
export const feSpecularLighting: HyperappTag
|
|
72
|
+
export const feComponentTransfer: HyperappTag
|
|
73
|
+
}
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
// An action-free tree can be embedded in an app with any state type.
|
|
2
|
+
type PassiveProps = import("hyperapp").Props<any> & {
|
|
3
|
+
[K in keyof import("hyperapp").EventActions<any>]?: never
|
|
4
|
+
}
|
|
5
|
+
|
|
6
|
+
type PassiveChild = boolean | null | undefined | import("hyperapp").TextVNode | PassiveVNode
|
|
7
|
+
type PassiveChildren = PassiveChild | readonly PassiveChild[]
|
|
8
|
+
|
|
9
|
+
type PassiveVNode = Omit<
|
|
10
|
+
import("hyperapp").ElementVNode<any>,
|
|
11
|
+
"props" | "children" | "events" | "tag" | "memo"
|
|
12
|
+
> & {
|
|
13
|
+
readonly props: PassiveProps
|
|
14
|
+
readonly children: readonly PassiveChild[]
|
|
15
|
+
readonly tag: string
|
|
16
|
+
events?: never
|
|
17
|
+
memo?: never
|
|
18
|
+
}
|
|
19
|
+
|
|
20
|
+
type HyperappChildren<S> =
|
|
21
|
+
| import("hyperapp").MaybeVNode<S>
|
|
22
|
+
| PassiveChild
|
|
23
|
+
| readonly (import("hyperapp").MaybeVNode<S> | PassiveChild)[]
|
|
24
|
+
|
|
25
|
+
interface HyperappTag {
|
|
26
|
+
(props: PassiveProps, children?: PassiveChildren): PassiveVNode
|
|
27
|
+
(children: PassiveChildren): PassiveVNode
|
|
28
|
+
<S>(props: import("hyperapp").Props<S>, children?: HyperappChildren<S>): import("hyperapp").ElementVNode<S>
|
|
29
|
+
<S>(children: import("hyperapp").VNode<S> | readonly (import("hyperapp").MaybeVNode<S> | PassiveChild)[]): import("hyperapp").ElementVNode<S>
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
interface HyperappHtmlTag extends HyperappTag {
|
|
33
|
+
(): PassiveVNode
|
|
34
|
+
}
|