@evertondgn/solid-tooling 0.4.0 → 0.6.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 +193 -578
- package/app-env.d.ts +7 -0
- package/dist/architecture-plugin.mjs +1 -1
- package/dist/backend-plugin.mjs +139 -4
- package/dist/cli.d.mts +1 -0
- package/dist/cli.mjs +42 -0
- package/dist/commitlint.d.mts +3 -0
- package/dist/commitlint.mjs +28 -0
- package/dist/{constants-Jqvtbvxu.mjs → constants-BZJm7ouk.mjs} +1 -1
- package/dist/css-filename-CEHQd2gz.mjs +40 -0
- package/dist/css-filename.mjs +1 -40
- package/dist/fmt-9dlUYOMk.mjs +34 -0
- package/dist/fmt.mjs +1 -34
- package/dist/i18n-generate.d.mts +1 -0
- package/dist/i18n-generate.mjs +23 -0
- package/dist/i18nPlugin-CS7Gob6R.mjs +109 -0
- package/dist/knip.d.mts +2 -1
- package/dist/knip.mjs +7 -2
- package/dist/{lint-UTfyg7AR.mjs → lint-ehdtTKfw.mjs} +33 -86
- package/dist/lint.mjs +1 -1
- package/dist/playwright-teardown.mjs +1 -1
- package/dist/playwright.d.mts +2 -1
- package/dist/playwright.mjs +4 -3
- package/dist/prepareMessages-BXmY6Ko2.mjs +222 -0
- package/dist/project-plugin.mjs +2 -2
- package/dist/protocol-DSNNUYja.mjs +18 -0
- package/dist/publication/read-llms-index.d.mts +12 -0
- package/dist/publication/read-llms-index.mjs +1 -0
- package/dist/publication-CRUTOB0B.mjs +885 -0
- package/dist/readLlmsIndex-Gj4iTxAk.mjs +27 -0
- package/dist/stylelint.mjs +2 -2
- package/dist/test-locale--tuH0Np5.mjs +3 -0
- package/dist/types-DHu2Z_ot.d.mts +49 -0
- package/dist/vite.d.mts +33 -7
- package/dist/vite.mjs +415 -88
- package/dist/vitest-BjLr7iLf.mjs +362 -0
- package/dist/vitest.d.mts +3 -7
- package/dist/vitest.mjs +1 -129
- package/lefthook.yml +57 -0
- package/node-env.d.ts +1 -0
- package/package.json +54 -35
- package/tsconfig.app.json +4 -9
- package/virtual-modules.d.ts +90 -0
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@evertondgn/solid-tooling",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.6.0",
|
|
4
4
|
"description": "Lint, formatter, TypeScript, test and Vite app presets for SolidJS applications built with Vite+.",
|
|
5
5
|
"author": "Éverton Toffanetto",
|
|
6
6
|
"license": "MIT",
|
|
@@ -11,27 +11,49 @@
|
|
|
11
11
|
},
|
|
12
12
|
"keywords": [
|
|
13
13
|
"solidjs",
|
|
14
|
+
"solid",
|
|
15
|
+
"vite",
|
|
14
16
|
"vite-plus",
|
|
17
|
+
"nitro",
|
|
18
|
+
"ssr",
|
|
15
19
|
"oxlint",
|
|
20
|
+
"oxfmt",
|
|
16
21
|
"lint",
|
|
17
|
-
"
|
|
22
|
+
"formatter",
|
|
23
|
+
"tsconfig",
|
|
24
|
+
"typescript",
|
|
25
|
+
"vitest",
|
|
26
|
+
"playwright",
|
|
27
|
+
"knip",
|
|
28
|
+
"stylelint",
|
|
29
|
+
"paraglide",
|
|
30
|
+
"i18n",
|
|
31
|
+
"preset"
|
|
18
32
|
],
|
|
19
33
|
"type": "module",
|
|
20
34
|
"files": [
|
|
21
35
|
"dist",
|
|
22
36
|
"tsconfig.base.json",
|
|
23
|
-
"tsconfig.app.json"
|
|
37
|
+
"tsconfig.app.json",
|
|
38
|
+
"virtual-modules.d.ts",
|
|
39
|
+
"lefthook.yml",
|
|
40
|
+
"app-env.d.ts",
|
|
41
|
+
"node-env.d.ts"
|
|
24
42
|
],
|
|
25
43
|
"exports": {
|
|
26
44
|
"./architecture-plugin": "./dist/architecture-plugin.mjs",
|
|
27
45
|
"./backend-plugin": "./dist/backend-plugin.mjs",
|
|
46
|
+
"./cli": "./dist/cli.mjs",
|
|
47
|
+
"./commitlint": "./dist/commitlint.mjs",
|
|
28
48
|
"./css-filename": "./dist/css-filename.mjs",
|
|
29
49
|
"./fmt": "./dist/fmt.mjs",
|
|
50
|
+
"./i18n-generate": "./dist/i18n-generate.mjs",
|
|
30
51
|
"./knip": "./dist/knip.mjs",
|
|
31
52
|
"./lint": "./dist/lint.mjs",
|
|
32
53
|
"./playwright": "./dist/playwright.mjs",
|
|
33
54
|
"./playwright-teardown": "./dist/playwright-teardown.mjs",
|
|
34
55
|
"./project-plugin": "./dist/project-plugin.mjs",
|
|
56
|
+
"./publication/read-llms-index": "./dist/publication/read-llms-index.mjs",
|
|
35
57
|
"./solid-plugin": "./dist/solid-plugin.mjs",
|
|
36
58
|
"./stylelint": "./dist/stylelint.mjs",
|
|
37
59
|
"./vite": "./dist/vite.mjs",
|
|
@@ -39,7 +61,14 @@
|
|
|
39
61
|
"./vitest-setup/browser": "./dist/vitest-setup/browser.mjs",
|
|
40
62
|
"./package.json": "./package.json",
|
|
41
63
|
"./tsconfig.base.json": "./tsconfig.base.json",
|
|
42
|
-
"./tsconfig.app.json": "./tsconfig.app.json"
|
|
64
|
+
"./tsconfig.app.json": "./tsconfig.app.json",
|
|
65
|
+
"./app-env": {
|
|
66
|
+
"types": "./app-env.d.ts"
|
|
67
|
+
},
|
|
68
|
+
"./virtual-modules": {
|
|
69
|
+
"types": "./virtual-modules.d.ts"
|
|
70
|
+
},
|
|
71
|
+
"./lefthook.yml": "./lefthook.yml"
|
|
43
72
|
},
|
|
44
73
|
"publishConfig": {
|
|
45
74
|
"access": "public"
|
|
@@ -51,50 +80,40 @@
|
|
|
51
80
|
"test:tarball": "vp run test-tarball"
|
|
52
81
|
},
|
|
53
82
|
"dependencies": {
|
|
83
|
+
"@commitlint/config-conventional": "21.2.4",
|
|
54
84
|
"eslint-plugin-solid": "0.19.0",
|
|
55
85
|
"stylelint": "18.0.0",
|
|
56
|
-
"stylelint-use-nesting": "6.0.2"
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
"@inlang/paraglide-js": "3.2.2",
|
|
60
|
-
"vite-plus": "1.6.0",
|
|
86
|
+
"stylelint-use-nesting": "6.0.2",
|
|
87
|
+
"@inlang/sdk": "4.2.0",
|
|
88
|
+
"valibot": "1.5.0",
|
|
61
89
|
"@playwright/test": "1.65.0",
|
|
62
90
|
"@solidjs/vite-plugin": "3.0.0-next.57",
|
|
63
91
|
"filesystem-routing": "0.5.0",
|
|
64
92
|
"knip": "6.45.1",
|
|
65
93
|
"nitro": "3.0.261103-rc",
|
|
66
|
-
"unplugin-icons": "24.0.0"
|
|
94
|
+
"unplugin-icons": "24.0.0",
|
|
95
|
+
"@commitlint/cli": "21.2.4",
|
|
96
|
+
"lefthook": "2.2.2",
|
|
97
|
+
"happy-dom": "21.0.4",
|
|
98
|
+
"playwright": "1.65.0",
|
|
99
|
+
"@vitest/browser-playwright": "5.1.0",
|
|
100
|
+
"@vitest/coverage-v8": "5.1.0",
|
|
101
|
+
"@vitest/ui": "5.1.0",
|
|
102
|
+
"@testing-library/jest-dom": "7.0.1",
|
|
103
|
+
"@types/node": "24.19.2",
|
|
104
|
+
"typescript": "7.0.2"
|
|
105
|
+
},
|
|
106
|
+
"peerDependencies": {
|
|
107
|
+
"@inlang/paraglide-js": "3.2.2",
|
|
108
|
+
"vite-plus": "1.6.0"
|
|
67
109
|
},
|
|
68
110
|
"devDependencies": {
|
|
69
111
|
"@inlang/paraglide-js": "3.2.2",
|
|
70
|
-
"@types/node": "24.19.2",
|
|
71
|
-
"typescript": "7.0.2",
|
|
72
|
-
"valibot": "1.5.0",
|
|
73
112
|
"vite-plus": "1.6.0",
|
|
74
|
-
"@
|
|
75
|
-
"@solidjs/vite-plugin": "3.0.0-next.57",
|
|
76
|
-
"filesystem-routing": "0.5.0",
|
|
77
|
-
"knip": "6.45.1",
|
|
78
|
-
"nitro": "3.0.261103-rc",
|
|
79
|
-
"unplugin-icons": "24.0.0"
|
|
113
|
+
"@inlang/plugin-message-format": "4.6.0"
|
|
80
114
|
},
|
|
81
115
|
"peerDependenciesMeta": {
|
|
82
|
-
"@
|
|
83
|
-
"optional": true
|
|
84
|
-
},
|
|
85
|
-
"@solidjs/vite-plugin": {
|
|
86
|
-
"optional": true
|
|
87
|
-
},
|
|
88
|
-
"filesystem-routing": {
|
|
89
|
-
"optional": true
|
|
90
|
-
},
|
|
91
|
-
"knip": {
|
|
92
|
-
"optional": true
|
|
93
|
-
},
|
|
94
|
-
"nitro": {
|
|
95
|
-
"optional": true
|
|
96
|
-
},
|
|
97
|
-
"unplugin-icons": {
|
|
116
|
+
"@inlang/paraglide-js": {
|
|
98
117
|
"optional": true
|
|
99
118
|
}
|
|
100
119
|
}
|
package/tsconfig.app.json
CHANGED
|
@@ -1,14 +1,8 @@
|
|
|
1
1
|
{
|
|
2
2
|
"extends": "./tsconfig.base.json",
|
|
3
3
|
"compilerOptions": {
|
|
4
|
-
"
|
|
5
|
-
|
|
6
|
-
"vite/client",
|
|
7
|
-
"vite-plus/test/globals",
|
|
8
|
-
"@testing-library/jest-dom/vitest",
|
|
9
|
-
"@solidjs/vite-plugin/boundary-modules",
|
|
10
|
-
"@solidjs/vite-plugin/virtual-modules"
|
|
11
|
-
]
|
|
4
|
+
"customConditions": ["solid"],
|
|
5
|
+
"types": ["@evertondgn/solid-tooling/app-env"]
|
|
12
6
|
},
|
|
13
7
|
"include": [
|
|
14
8
|
"${configDir}/src",
|
|
@@ -17,5 +11,6 @@
|
|
|
17
11
|
"${configDir}/vite.config.ts",
|
|
18
12
|
"${configDir}/playwright.config.ts",
|
|
19
13
|
"${configDir}/tooling/**/*.ts"
|
|
20
|
-
]
|
|
14
|
+
],
|
|
15
|
+
"files": ["./node-env.d.ts"]
|
|
21
16
|
}
|
|
@@ -0,0 +1,90 @@
|
|
|
1
|
+
declare module 'virtual:solid-app/fonts' {
|
|
2
|
+
type FontPreload = { href: string; type: string }
|
|
3
|
+
export const stylesheet: string
|
|
4
|
+
export const preloads: readonly FontPreload[]
|
|
5
|
+
}
|
|
6
|
+
|
|
7
|
+
declare module 'virtual:solid-app/seo-origin' {
|
|
8
|
+
export const origin: string
|
|
9
|
+
}
|
|
10
|
+
|
|
11
|
+
declare module 'virtual:solid-app/seo-markdown' {
|
|
12
|
+
type MarkdownConfig = {
|
|
13
|
+
static: boolean
|
|
14
|
+
maxInputBytes: number
|
|
15
|
+
maxOutputBytes: number
|
|
16
|
+
timeoutMs: number
|
|
17
|
+
hasLlms: boolean
|
|
18
|
+
}
|
|
19
|
+
export const markdown: MarkdownConfig
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
declare module 'virtual:solid-app/seo-llms' {
|
|
23
|
+
type LlmsConfig = {
|
|
24
|
+
maxBytes: number
|
|
25
|
+
hasMarkdown: boolean
|
|
26
|
+
hasLlmsFull: boolean
|
|
27
|
+
}
|
|
28
|
+
export const llms: LlmsConfig
|
|
29
|
+
}
|
|
30
|
+
|
|
31
|
+
declare module 'virtual:solid-app/locale-context' {
|
|
32
|
+
type ContextOptions = { url: string; run: () => Response | Promise<Response> }
|
|
33
|
+
export function withLocaleContext(options: ContextOptions): Promise<Response>
|
|
34
|
+
export function requestLocale(request: Request): string
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
declare module 'virtual:solid-app/seo-robots' {
|
|
38
|
+
type RobotsGroup = {
|
|
39
|
+
userAgents: readonly string[]
|
|
40
|
+
allow?: readonly string[]
|
|
41
|
+
disallow?: readonly string[]
|
|
42
|
+
}
|
|
43
|
+
type RobotsConfig = {
|
|
44
|
+
groups: readonly RobotsGroup[]
|
|
45
|
+
sitemaps: readonly string[]
|
|
46
|
+
cacheControl?: string
|
|
47
|
+
}
|
|
48
|
+
export const robots: RobotsConfig
|
|
49
|
+
}
|
|
50
|
+
|
|
51
|
+
declare module 'virtual:solid-app/locale' {
|
|
52
|
+
type UrlInput = string | { readonly href: string }
|
|
53
|
+
type LocalizeOptions = { locale?: string }
|
|
54
|
+
type SetLocaleOptions = { reload?: boolean }
|
|
55
|
+
export const locales: readonly string[]
|
|
56
|
+
export const baseLocale: string
|
|
57
|
+
export function getLocale(): string
|
|
58
|
+
export function setLocale(
|
|
59
|
+
locale: string,
|
|
60
|
+
options?: SetLocaleOptions
|
|
61
|
+
): void | Promise<void>
|
|
62
|
+
export function extractLocaleFromUrl(url: URL | string): string | undefined
|
|
63
|
+
export function localizeHref(href: string, options?: LocalizeOptions): string
|
|
64
|
+
export function deLocalizeUrl(url: UrlInput): URL
|
|
65
|
+
}
|
|
66
|
+
|
|
67
|
+
declare module 'virtual:solid-app/request-middleware' {
|
|
68
|
+
type Security = { applySecurityHeaders: (response: Response) => Response }
|
|
69
|
+
type RequestOptions = { request: Request; next: () => Promise<Response> }
|
|
70
|
+
export function createRequestLocale(
|
|
71
|
+
options: Security
|
|
72
|
+
): (options: RequestOptions) => Promise<Response>
|
|
73
|
+
}
|
|
74
|
+
|
|
75
|
+
declare module 'virtual:solid-app/locale-request' {
|
|
76
|
+
type Decision = { shouldRedirect: boolean; redirectUrl?: URL; locale: string }
|
|
77
|
+
type Options = { request: Request }
|
|
78
|
+
type Context = { locale: string; request: Request }
|
|
79
|
+
export function shouldRedirect(options: Options): Promise<Decision>
|
|
80
|
+
export function extractLocaleFromRequest(request: Request): string
|
|
81
|
+
export function paraglideMiddleware(
|
|
82
|
+
request: Request,
|
|
83
|
+
next: (context: Context) => Promise<Response>
|
|
84
|
+
): Promise<Response>
|
|
85
|
+
export const cookieName: string
|
|
86
|
+
export const cookieMaxAge: number
|
|
87
|
+
export const cookieDomain: string
|
|
88
|
+
export const cookieSameSite: 'lax' | 'strict' | 'none'
|
|
89
|
+
export const cookieSecure: boolean | 'auto'
|
|
90
|
+
}
|