stacks 0.58.28 → 0.58.30

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.
Files changed (233) hide show
  1. package/core/README.md +1 -1
  2. package/core/actions/dist/src/deploy/index.js +1 -1
  3. package/core/actions/dist/src/dev/components.js +1 -1
  4. package/core/actions/dist/src/dev/index.js +10 -0
  5. package/core/actions/dist/src/generate/lib-entries.js +3 -3
  6. package/core/actions/dist/src/helpers/lib-entries.js +3 -3
  7. package/core/actions/dist/src/index.js +10 -0
  8. package/core/actions/dist/src/lint/fix.js +1 -1
  9. package/core/actions/dist/src/release.js +8 -0
  10. package/core/actions/dist/src/upgrade.js +1 -1
  11. package/core/actions/package.json +1 -1
  12. package/core/actions/src/build/docs.ts +7 -0
  13. package/core/actions/src/deploy/index.ts +1 -1
  14. package/core/actions/src/dev/api.ts +2 -2
  15. package/core/actions/src/dev/components.ts +1 -1
  16. package/core/actions/src/dev/dashboard.ts +7 -0
  17. package/core/actions/src/dev/desktop.ts +3 -3
  18. package/core/actions/src/dev/index.ts +10 -0
  19. package/core/actions/src/dev/system-tray.ts +6 -0
  20. package/core/actions/src/helpers/lib-entries.ts +3 -3
  21. package/core/actions/src/lint/fix.ts +1 -1
  22. package/core/ai/package.json +3 -3
  23. package/core/alias/package.json +1 -1
  24. package/core/analytics/package.json +1 -1
  25. package/core/api/package.json +1 -1
  26. package/core/arrays/package.json +1 -1
  27. package/core/auth/package.json +1 -1
  28. package/core/buddy/README.md +2 -2
  29. package/core/buddy/dist/{chunk-b75e6db0012faa55.js → chunk-0455e53fab4244b1.js} +1 -4
  30. package/core/buddy/dist/{chunk-fd47b42fb923a4be.js → chunk-61e8f138963fc709.js} +173 -137
  31. package/core/buddy/dist/cli.js +2 -2
  32. package/core/buddy/dist/index.js +2 -2
  33. package/core/buddy/package.json +1 -1
  34. package/core/buddy/src/commands/add.ts +4 -0
  35. package/core/buddy/src/commands/build.ts +12 -1
  36. package/core/buddy/src/commands/changelog.ts +2 -0
  37. package/core/buddy/src/commands/clean.ts +2 -0
  38. package/core/buddy/src/commands/cloud.ts +6 -0
  39. package/core/buddy/src/commands/commit.ts +2 -0
  40. package/core/buddy/src/commands/configure.ts +3 -0
  41. package/core/buddy/src/commands/create.ts +8 -8
  42. package/core/buddy/src/commands/deploy.ts +24 -23
  43. package/core/buddy/src/commands/dev.ts +50 -10
  44. package/core/buddy/src/commands/dns.ts +2 -0
  45. package/core/buddy/src/commands/domains.ts +2 -0
  46. package/core/buddy/src/commands/example.ts +4 -0
  47. package/core/buddy/src/commands/fresh.ts +2 -0
  48. package/core/buddy/src/commands/generate.ts +12 -3
  49. package/core/buddy/src/commands/http.ts +2 -0
  50. package/core/buddy/src/commands/install.ts +2 -0
  51. package/core/buddy/src/commands/key.ts +4 -2
  52. package/core/buddy/src/commands/lint.ts +3 -0
  53. package/core/buddy/src/commands/make.ts +11 -1
  54. package/core/buddy/src/commands/migrate.ts +3 -0
  55. package/core/buddy/src/commands/prepublish.ts +2 -0
  56. package/core/buddy/src/commands/release.ts +2 -0
  57. package/core/buddy/src/commands/seed.ts +2 -0
  58. package/core/buddy/src/commands/setup.ts +33 -34
  59. package/core/buddy/src/commands/test.ts +2 -0
  60. package/core/buddy/src/commands/tinker.ts +2 -0
  61. package/core/buddy/src/commands/types.ts +3 -0
  62. package/core/buddy/src/commands/upgrade.ts +6 -0
  63. package/core/build/package.json +1 -1
  64. package/core/bun-create/bud/package.json +3 -2
  65. package/core/bun-create/buddy/package.json +2 -2
  66. package/core/bun-create/stack/package.json +2 -2
  67. package/core/bun-create/stacks/package.json +2 -2
  68. package/core/bun-create/stx/package.json +2 -2
  69. package/core/bun-plugin-yaml/dist/index.js +1 -19
  70. package/core/bun-plugin-yaml/package.json +1 -1
  71. package/core/bun-plugin-yaml/src/index.ts +1 -1
  72. package/core/cache/package.json +2 -2
  73. package/core/chat/package.json +1 -1
  74. package/core/cli/dist/index.js +24 -23
  75. package/core/cli/package.json +1 -1
  76. package/core/cli/src/helpers.ts +21 -31
  77. package/core/cli/src/run.ts +9 -7
  78. package/core/cloud/buddy +2 -0
  79. package/core/cloud/package.json +33 -33
  80. package/core/cloud/src/cloud/ai.ts +45 -36
  81. package/core/cloud/src/cloud/aws-sdk-layer/nodejs/package-lock.json +10 -10
  82. package/core/cloud/src/cloud/aws-sdk-layer/nodejs/package.json +2 -2
  83. package/core/cloud/src/cloud/cdn.ts +44 -5
  84. package/core/cloud/src/cloud/cli.ts +45 -0
  85. package/core/cloud/src/cloud/compute.ts +1 -1
  86. package/core/cloud/src/cloud/index.ts +6 -1
  87. package/core/cloud/src/cloud/lambda/cli-setup/index.js +67 -0
  88. package/core/cloud/src/index.ts +1 -0
  89. package/core/cloud/src/runtime/example/lambda.ts +1 -1
  90. package/core/cloud/src/runtime/runtime.ts +1 -0
  91. package/core/cloud/src/runtime/server.ts +1 -1
  92. package/core/collections/package.json +1 -1
  93. package/core/config/dist/index.js +130 -122
  94. package/core/config/package.json +1 -1
  95. package/core/config/src/overrides.ts +0 -2
  96. package/core/database/package.json +2 -2
  97. package/core/database/src/kysely-bun-worker/driver.ts +1 -0
  98. package/core/database/src/kysely-bun-worker/worker.ts +1 -1
  99. package/core/datetime/package.json +1 -1
  100. package/core/desktop/dist/index.js +6 -0
  101. package/core/desktop/package.json +5 -5
  102. package/core/desktop/src/index.ts +2 -0
  103. package/core/desktop/src/system-tray.ts +1 -0
  104. package/core/development/package.json +1 -1
  105. package/core/dns/package.json +7 -7
  106. package/core/docs/build.ts +1 -1
  107. package/core/docs/dist/index.js +29878 -9995
  108. package/core/docs/package.json +6 -5
  109. package/core/docs/src/index.ts +7 -1
  110. package/core/docs/src/meta.ts +32 -0
  111. package/core/docs/src/scripts/pwa.ts +116 -0
  112. package/core/email/email-forwarder.cjs +1 -0
  113. package/core/email/package.json +3 -3
  114. package/core/email/src/server/converter.ts +1 -0
  115. package/core/email/src/server/inbound.ts +1 -0
  116. package/core/email/src/server/outbound.ts +6 -4
  117. package/core/enums/dist/index.js +4 -2
  118. package/core/enums/package.json +1 -1
  119. package/core/enums/src/index.ts +4 -2
  120. package/core/env/package.json +1 -1
  121. package/core/error-handling/package.json +1 -1
  122. package/core/eslint-config/package.json +18 -18
  123. package/core/eslint-config/src/configs/comments.ts +1 -1
  124. package/core/eslint-config/src/configs/imports.ts +9 -0
  125. package/core/eslint-config/src/configs/svelte.ts +1 -0
  126. package/core/eslint-config/src/configs/unicorn.ts +1 -1
  127. package/core/eslint-config/src/configs/vue.ts +0 -1
  128. package/core/eslint-config/src/factory.ts +2 -8
  129. package/core/events/package.json +1 -1
  130. package/core/faker/package.json +2 -2
  131. package/core/git/dist/index.js +40 -0
  132. package/core/git/package.json +3 -3
  133. package/core/git/src/index.ts +62 -0
  134. package/core/health/package.json +1 -1
  135. package/core/http/package.json +1 -1
  136. package/core/lint/package.json +1 -1
  137. package/core/logging/dist/index.js +0 -6
  138. package/core/logging/package.json +1 -1
  139. package/core/music/package.json +3 -3
  140. package/core/notifications/package.json +2 -2
  141. package/core/objects/package.json +1 -1
  142. package/core/orm/package.json +1 -1
  143. package/core/path/dist/index.js +6 -3
  144. package/core/path/package.json +1 -1
  145. package/core/path/src/index.ts +7 -3
  146. package/core/payments/dist/index.js +2 -5
  147. package/core/payments/package.json +3 -3
  148. package/core/push/package.json +1 -1
  149. package/core/query-builder/package.json +1 -1
  150. package/core/queue/package.json +1 -1
  151. package/core/raycast/package.json +5 -0
  152. package/core/raycast/src/index.ts +0 -0
  153. package/core/realtime/package.json +1 -1
  154. package/core/repl/package.json +1 -1
  155. package/core/router/dist/index.js +16 -496
  156. package/core/router/package.json +1 -1
  157. package/core/router/src/middleware.ts +16 -14
  158. package/core/scheduler/package.json +1 -1
  159. package/core/search-engine/package.json +2 -2
  160. package/core/security/dist/index.js +3 -6
  161. package/core/security/package.json +2 -2
  162. package/core/server/dist/index.js +6 -2
  163. package/core/server/package.json +2 -2
  164. package/core/server/src/config.ts +14 -9
  165. package/core/signals/package.json +1 -1
  166. package/core/slug/package.json +1 -1
  167. package/core/sms/package.json +1 -1
  168. package/core/storage/dist/index.js +28 -10
  169. package/core/storage/package.json +1 -1
  170. package/core/storage/src/files.ts +10 -2
  171. package/core/storage/src/zip.ts +1 -1
  172. package/core/strings/package.json +3 -3
  173. package/core/stx +2 -0
  174. package/core/tables/package.json +3 -3
  175. package/core/testing/package.json +3 -3
  176. package/core/tinker/package.json +1 -1
  177. package/core/tsconfig.json +4 -9
  178. package/core/tunnel/package.json +1 -1
  179. package/core/types/dist/index.js +3 -1
  180. package/core/types/package.json +13 -13
  181. package/core/types/src/cli.ts +3 -3
  182. package/core/types/src/cloud.ts +4 -1
  183. package/core/types/src/dns.ts +1 -1
  184. package/core/types/src/native.ts +0 -0
  185. package/core/types/src/stacks.ts +0 -10
  186. package/core/ui/package.json +8 -8
  187. package/core/utils/dist/index.js +1 -1
  188. package/core/utils/package.json +1 -1
  189. package/core/validation/package.json +1 -1
  190. package/core/vite/README.md +1 -1
  191. package/core/vite/build.ts +1 -1
  192. package/core/vite/dist/index.js +211 -203
  193. package/core/vite/package.json +5 -5
  194. package/core/vite/src/components.ts +1 -1
  195. package/core/vite/src/dashboard.ts +100 -0
  196. package/core/vite/src/desktop.ts +2 -58
  197. package/core/vite/src/example-vue.ts +1 -1
  198. package/core/vite/src/example-wc.ts +1 -1
  199. package/core/vite/src/functions.ts +1 -1
  200. package/core/vite/src/index.ts +9 -11
  201. package/core/vite/src/plugin/auto-imports.ts +1 -1
  202. package/core/vite/src/plugin/layouts.ts +6 -7
  203. package/core/vite/src/plugin/router.ts +3 -1
  204. package/core/vite/src/system-tray.ts +100 -0
  205. package/core/vite/src/views.ts +13 -2
  206. package/core/vite/src/web-components.ts +1 -1
  207. package/core/whois/dist/index.js +1 -2
  208. package/core/whois/package.json +1 -1
  209. package/core/whois/src/index.ts +10 -8
  210. package/core/x-ray/package.json +1 -1
  211. package/core/zsh-buddy/README.md +51 -0
  212. package/core/zsh-buddy/package.json +29 -0
  213. package/ide/dictionary.txt +12 -0
  214. package/ide/jetbrains/.idea/stacks.iml +0 -1
  215. package/ide/vscode/.vscode/settings.json +7 -2
  216. package/ide/vscode/package.json +2 -4
  217. package/package.json +12 -7
  218. package/core/cloud/src/server/.dockerignore +0 -15
  219. package/core/cloud/src/server/Dockerfile +0 -21
  220. package/core/cloud/src/server/index.ts +0 -3
  221. package/core/cloud/src/server/package.json +0 -12
  222. package/core/cloud/src/server/runtime.ts +0 -828
  223. package/core/scripts/build +0 -58
  224. package/core/scripts/ensure +0 -33
  225. package/core/scripts/fresh +0 -14
  226. package/core/scripts/link +0 -14
  227. package/core/scripts/move-built-src-files.ts +0 -28
  228. package/core/scripts/move-dts-files.ts +0 -35
  229. package/core/scripts/publish +0 -43
  230. package/core/scripts/setup +0 -176
  231. package/core/tables/vite.config.ts +0 -84
  232. package/core/vite/src/plugin/index.ts +0 -21
  233. /package/core/vite/src/{stacks.ts → plugins.ts} +0 -0
@@ -0,0 +1,100 @@
1
+ import { path as p } from '@stacksjs/path'
2
+ import { defineConfig } from 'vite'
3
+ import Vue from '@vitejs/plugin-vue'
4
+ import generateSitemap from 'vite-ssg-sitemap'
5
+ import { server } from '@stacksjs/server'
6
+ import { alias } from '@stacksjs/alias'
7
+ import VueMacros from 'unplugin-vue-macros/vite'
8
+ import { config } from '@stacksjs/config'
9
+ import { autoImports, components, cssEngine, i18n, layouts, router } from './plugins'
10
+
11
+ // import { autoImports, components, cssEngine, devtools, i18n, layouts, markdown, pwa, router } from './stacks'
12
+
13
+ // import { fonts } from './plugin/fonts'
14
+
15
+ // const isMaintenanceMode = config.app.maintenanceMode
16
+ // const maintenancePath = isMaintenanceMode ? '' : './maintenance'
17
+
18
+ export default defineConfig({
19
+ build: {
20
+ rollupOptions: {
21
+ external: ['path', 'fs', 'net', 'tls', 'stream', 'node:process', 'constants', 'node:dns/promises', 'node:util'],
22
+ },
23
+ },
24
+
25
+ root: p.frameworkPath('views/dashboard'),
26
+ publicDir: p.publicPath(),
27
+ envDir: p.projectPath(),
28
+ envPrefix: 'FRONTEND_',
29
+
30
+ assetsInclude: [
31
+ p.resourcesPath('assets/*'),
32
+ p.resourcesPath('assets/**/*'),
33
+ ],
34
+
35
+ optimizeDeps: {
36
+ exclude: ['bun:test', 'webpack', 'chokidar', 'fsevents', '@intlify/unplugin-vue-i18n', '@stacksjs/ui'],
37
+ },
38
+
39
+ server: server({
40
+ type: 'dashboard',
41
+ }),
42
+
43
+ resolve: {
44
+ alias,
45
+ },
46
+
47
+ plugins: [
48
+ VueMacros({
49
+ plugins: {
50
+ vue: Vue({
51
+ include: /\.(stx|md)($|\?)/,
52
+ }),
53
+ },
54
+ }),
55
+
56
+ router({
57
+ extensions: ['.stx', '.md'],
58
+ dts: p.frameworkPath('types/dashboard-router.d.ts'),
59
+ routesFolder: [
60
+ p.resourcesPath('views/dashboard'),
61
+ ],
62
+ logs: config.app.debug || false,
63
+ }),
64
+
65
+ layouts({
66
+ extensions: ['stx'],
67
+ layoutsDirs: p.layoutsPath('dashboard', { relative: true }),
68
+ }),
69
+ autoImports(),
70
+ components(),
71
+ cssEngine(),
72
+ // markdown(),
73
+ // pwa(),
74
+ // devtools(),
75
+ i18n(),
76
+
77
+ // https://github.com/feat-agency/vite-plugin-webfont-dl
78
+ // fonts(),
79
+ // webfontDownload(),
80
+ ],
81
+
82
+ // https://github.com/antfu/vite-ssg
83
+ ssgOptions: {
84
+ script: 'async',
85
+ formatting: 'minify',
86
+
87
+ crittersOptions: {
88
+ reduceInlineStyles: false,
89
+ },
90
+
91
+ onFinished() {
92
+ generateSitemap()
93
+ },
94
+ },
95
+
96
+ ssr: {
97
+ // TODO: workaround until they support native ESM
98
+ noExternal: ['workbox-window', /vue-i18n/],
99
+ },
100
+ })
@@ -1,59 +1,3 @@
1
- import type { ViteConfig } from '@stacksjs/types'
2
- import { path as p } from '@stacksjs/path'
3
- import { alias } from '@stacksjs/alias'
4
- import generateSitemap from 'vite-ssg-sitemap'
5
- import { autoImports, components, cssEngine, layouts, pages, uiEngine } from './stacks'
6
- import { defineConfig } from '.'
1
+ import desktopConfig from './views'
7
2
 
8
- export const pagesConfig = {
9
- root: p.projectStoragePath('framework/dashboard'),
10
- envDir: p.projectPath(),
11
- envPrefix: 'FRONTEND_',
12
- publicDir: p.projectPath('public'),
13
-
14
- resolve: {
15
- alias,
16
- },
17
-
18
- server: {
19
- host: '127.0.0.1',
20
- port: 3333,
21
- },
22
-
23
- plugins: [
24
- pages({
25
- routesFolder: p.projectStoragePath('framework/dashboard/src/pages'),
26
- }),
27
-
28
- uiEngine(),
29
- components(),
30
- autoImports(),
31
- cssEngine(),
32
-
33
- layouts({
34
- layoutsDirs: p.resourcesPath('layouts'),
35
- }, false),
36
- ],
37
-
38
- // https://github.com/antfu/vite-ssg
39
- ssgOptions: {
40
- script: 'async',
41
- formatting: 'minify',
42
- onFinished() {
43
- generateSitemap()
44
- },
45
- },
46
-
47
- ssr: {
48
- // TODO: workaround until they support native ESM
49
- noExternal: ['workbox-window', /vue-i18n/],
50
- },
51
- } satisfies ViteConfig
52
-
53
- export default defineConfig(({ command }) => {
54
- if (command === 'serve')
55
- return pagesConfig
56
-
57
- // command === 'build'
58
- return pagesConfig
59
- })
3
+ export default desktopConfig
@@ -2,7 +2,7 @@ import type { ViteConfig } from '@stacksjs/types'
2
2
  import { examplesPath } from '@stacksjs/path'
3
3
  import { server } from '@stacksjs/server'
4
4
  import { alias } from '@stacksjs/alias'
5
- import { defineConfig } from '.'
5
+ import { defineConfig } from 'vite'
6
6
 
7
7
  // import { uiEngine } from '.'
8
8
 
@@ -2,7 +2,7 @@ import type { ViteConfig } from '@stacksjs/types'
2
2
  import { examplesPath } from '@stacksjs/path'
3
3
  import { server } from '@stacksjs/server'
4
4
  import { alias } from '@stacksjs/alias'
5
- import { defineConfig } from '.'
5
+ import { defineConfig } from 'vite'
6
6
 
7
7
  // import { uiEngine } from '.'
8
8
 
@@ -1,7 +1,7 @@
1
1
  import type { ViteConfig } from '@stacksjs/types'
2
2
  import { frameworkPath, functionsPath, libraryEntryPath, projectPath } from '@stacksjs/path'
3
3
  import { alias } from '@stacksjs/alias'
4
- import { defineConfig } from '.'
4
+ import { defineConfig } from 'vite'
5
5
  import type { ViteBuildOptions } from '.'
6
6
 
7
7
  // import { autoImports } from '.'
@@ -1,6 +1,9 @@
1
- import { defineConfig, loadEnv as viteLoadEnv } from 'vite'
2
- import type { BuildOptions as ViteBuildOptions, ViteDevServer } from 'vite'
3
- import type { Env } from '@stacksjs/env'
1
+ // import type { BuildOptions as ViteBuildOptions, ViteDevServer } from 'vite'
2
+ // import type { Env } from '@stacksjs/env'
3
+
4
+ // export function loadEnv(...args: Parameters<typeof viteLoadEnv>): Env {
5
+ // return viteLoadEnv(...args) as unknown as Env
6
+ // }
4
7
 
5
8
  export * as vueComponentExample from './example-vue'
6
9
  export * as webComponentExample from './example-wc'
@@ -8,13 +11,8 @@ export * as functions from './functions'
8
11
  export * as views from './views'
9
12
  export * as vueComponents from './components'
10
13
  export * as webComponents from './web-components'
11
- export * from './stacks'
12
- export * as stacks from './stacks'
14
+ export * from './plugins'
15
+ export * as stacks from './plugins'
13
16
  export { docsEngine } from './plugin/docs'
14
17
 
15
- function loadEnv(...args: Parameters<typeof viteLoadEnv>): Env {
16
- return viteLoadEnv(...args) as unknown as Env
17
- }
18
-
19
- export { defineConfig, loadEnv }
20
- export { ViteDevServer, ViteBuildOptions }
18
+ // export { ViteDevServer, ViteBuildOptions }
@@ -7,7 +7,7 @@ import { VueRouterAutoImports } from 'unplugin-vue-router'
7
7
 
8
8
  export function autoImports(options?: AutoImportsOptions): Plugin {
9
9
  return AutoImport({
10
- include: /\.(stx|vue|js|ts|mdx?|elm|html)($|\?)/,
10
+ include: /\.(stx|js|ts|mdx?|elm|html)($|\?)/,
11
11
  imports: [
12
12
  'pinia',
13
13
  'vue',
@@ -2,17 +2,16 @@ import { path as p } from '@stacksjs/path'
2
2
  import Layouts from 'vite-plugin-vue-layouts'
3
3
  import type { UserOptions as LayoutOptions } from 'vite-plugin-vue-layouts'
4
4
 
5
- export function layouts(options?: LayoutOptions, isMain = true) {
6
- if (!isMain)
7
- return Layouts(options)
8
-
9
- return Layouts({
5
+ export function layouts(options?: LayoutOptions) {
6
+ const opts = {
10
7
  extensions: ['stx', 'vue'],
11
8
  layoutsDirs: p.layoutsPath(),
12
- defaultLayout: p.layoutsPath('default.stx'),
13
9
  exclude: [
10
+ p.layoutsPath('dashboard'),
14
11
  p.layoutsPath('mails'),
15
12
  ],
16
13
  ...options,
17
- })
14
+ }
15
+
16
+ return Layouts(opts)
18
17
  }
@@ -1,9 +1,10 @@
1
1
  import { config } from '@stacksjs/config'
2
2
  import VueRouter from 'unplugin-vue-router/vite'
3
+ import type { Options as RouterOptions } from 'unplugin-vue-router'
3
4
  import { path as p } from '@stacksjs/path'
4
5
 
5
6
  // https://github.com/posva/unplugin-vue-router
6
- export function router() {
7
+ export function router(options?: RouterOptions) {
7
8
  return VueRouter({
8
9
  extensions: ['.stx', '.md'],
9
10
  dts: p.frameworkPath('types/router.d.ts'),
@@ -11,5 +12,6 @@ export function router() {
11
12
  p.resourcesPath('views'),
12
13
  ],
13
14
  logs: config.app.debug || false,
15
+ ...options,
14
16
  })
15
17
  }
@@ -0,0 +1,100 @@
1
+ import { path as p } from '@stacksjs/path'
2
+ import { defineConfig } from 'vite'
3
+ import Vue from '@vitejs/plugin-vue'
4
+ import generateSitemap from 'vite-ssg-sitemap'
5
+ import { server } from '@stacksjs/server'
6
+ import { alias } from '@stacksjs/alias'
7
+ import VueMacros from 'unplugin-vue-macros/vite'
8
+ import { config } from '@stacksjs/config'
9
+ import { cssEngine, i18n, layouts, router } from './plugins'
10
+
11
+ // import { autoImports, components, cssEngine, devtools, i18n, layouts, markdown, pwa, router } from './stacks'
12
+
13
+ // import { fonts } from './plugin/fonts'
14
+
15
+ // const isMaintenanceMode = config.app.maintenanceMode
16
+ // const maintenancePath = isMaintenanceMode ? '' : './maintenance'
17
+
18
+ export default defineConfig({
19
+ build: {
20
+ rollupOptions: {
21
+ external: ['path', 'fs', 'net', 'tls', 'stream', 'node:process', 'constants', 'node:dns/promises', 'node:util'],
22
+ },
23
+ },
24
+
25
+ root: p.frameworkPath('system-tray'),
26
+ publicDir: p.publicPath(),
27
+ envDir: p.projectPath(),
28
+ envPrefix: 'FRONTEND_',
29
+
30
+ assetsInclude: [
31
+ p.resourcesPath('assets/*'),
32
+ p.resourcesPath('assets/**/*'),
33
+ ],
34
+
35
+ optimizeDeps: {
36
+ exclude: ['bun:test', 'webpack', 'chokidar', 'fsevents', '@intlify/unplugin-vue-i18n', '@stacksjs/ui'],
37
+ },
38
+
39
+ server: server({
40
+ type: 'system-tray',
41
+ }),
42
+
43
+ resolve: {
44
+ alias,
45
+ },
46
+
47
+ plugins: [
48
+ VueMacros({
49
+ plugins: {
50
+ vue: Vue({
51
+ include: /\.(stx|md)($|\?)/,
52
+ }),
53
+ },
54
+ }),
55
+
56
+ router({
57
+ extensions: ['.stx', '.md'],
58
+ dts: p.frameworkPath('types/system-tray-router.d.ts'),
59
+ routesFolder: [
60
+ p.resourcesPath('views/system-tray'),
61
+ ],
62
+ logs: config.app.debug || false,
63
+ }),
64
+
65
+ layouts({
66
+ extensions: ['stx'],
67
+ layoutsDirs: p.layoutsPath('system-tray', { relative: true }),
68
+ }),
69
+ // autoImports(),
70
+ // components(),
71
+ cssEngine(),
72
+ // markdown(),
73
+ // pwa(),
74
+ // devtools(),
75
+ i18n(),
76
+
77
+ // https://github.com/feat-agency/vite-plugin-webfont-dl
78
+ // fonts(),
79
+ // webfontDownload(),
80
+ ],
81
+
82
+ // https://github.com/antfu/vite-ssg
83
+ ssgOptions: {
84
+ script: 'async',
85
+ formatting: 'minify',
86
+
87
+ crittersOptions: {
88
+ reduceInlineStyles: false,
89
+ },
90
+
91
+ onFinished() {
92
+ generateSitemap()
93
+ },
94
+ },
95
+
96
+ ssr: {
97
+ // TODO: workaround until they support native ESM
98
+ noExternal: ['workbox-window', /vue-i18n/],
99
+ },
100
+ })
@@ -5,7 +5,15 @@ import generateSitemap from 'vite-ssg-sitemap'
5
5
  import { server } from '@stacksjs/server'
6
6
  import { alias } from '@stacksjs/alias'
7
7
  import VueMacros from 'unplugin-vue-macros/vite'
8
- import { autoImports, components, cssEngine, devtools, i18n, layouts, markdown, pwa, router } from './stacks'
8
+ import { autoImports } from './plugin/auto-imports'
9
+ import { components } from './plugin/components'
10
+ import { cssEngine } from './plugin/css-engine'
11
+ import { devtools } from './plugin/devtools'
12
+ import { i18n } from './plugin/i18n'
13
+ import { layouts } from './plugin/layouts'
14
+ import { markdown } from './plugin/markdown'
15
+ import { pwa } from './plugin/pwa'
16
+ import { router } from './plugin/router'
9
17
 
10
18
  // import { fonts } from './plugin/fonts'
11
19
 
@@ -51,7 +59,10 @@ export default defineConfig({
51
59
  }),
52
60
 
53
61
  router(),
54
- layouts(),
62
+ layouts({
63
+ extensions: ['stx', 'vue'],
64
+ layoutsDirs: p.layoutsPath('', { relative: true }),
65
+ }),
55
66
  autoImports(),
56
67
  components(),
57
68
  cssEngine(),
@@ -2,8 +2,8 @@ import type { ViteConfig } from '@stacksjs/types'
2
2
  import { path as p } from '@stacksjs/path'
3
3
  import { server } from '@stacksjs/server'
4
4
  import { alias } from '@stacksjs/alias'
5
+ import { defineConfig } from 'vite'
5
6
  import type { ViteBuildOptions } from '.'
6
- import { defineConfig } from '.'
7
7
 
8
8
  // import { autoImports, components, cssEngine, inspect, uiEngine } from '.'
9
9
 
@@ -452,7 +452,6 @@ async function whois(domain, parse = false, options = null) {
452
452
  let tld;
453
453
  let port = 43;
454
454
  let server = "";
455
- let queryOptions;
456
455
  let proxy;
457
456
  let encoding = "utf-8";
458
457
  if (!options) {
@@ -482,7 +481,7 @@ async function whois(domain, parse = false, options = null) {
482
481
  server = serverData;
483
482
  }
484
483
  const qOptions = getParameters(server);
485
- queryOptions = qOptions || "";
484
+ const queryOptions = qOptions || "";
486
485
  try {
487
486
  const rawData = await tcpWhois(domain, queryOptions, server, port, encoding, proxy);
488
487
  if (!parse) {
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@stacksjs/whois",
3
3
  "type": "module",
4
- "version": "0.58.28",
4
+ "version": "0.58.30",
5
5
  "description": "Easily get whois info.",
6
6
  "author": "Chris Breuer",
7
7
  "license": "MIT",
@@ -1,5 +1,3 @@
1
- /* eslint-disable */
2
-
3
1
  import Net from 'node:net'
4
2
  import fetch from 'node-fetch'
5
3
  import type { SocksClientOptions } from 'socks'
@@ -39,6 +37,7 @@ async function findWhoIsServer(tld: string): Promise<string> {
39
37
  * @param obj Object which needs to be copied
40
38
  * @returns A copy of the object
41
39
  */
40
+ // eslint-disable-next-line ts/no-unnecessary-type-constraint
42
41
  function shallowCopy<T extends any>(obj: T): T {
43
42
  if (Array.isArray(obj)) {
44
43
  return obj.slice() as T // Clone the array
@@ -95,6 +94,7 @@ function getTLD(domain: string): keyof typeof SERVERS {
95
94
  if (tld)
96
95
  return tld
97
96
 
97
+ // eslint-disable-next-line no-console
98
98
  console.debug('TLD is not found in server list. Returning last element after split as TLD!')
99
99
 
100
100
  const domainData = domain.split('.')
@@ -185,7 +185,7 @@ export interface WhoIsOptions {
185
185
  *
186
186
  * @example {'Domain Name': '', 'Domain Status': [], 'Registrar': ''}
187
187
  */
188
- parseData?: Object | null
188
+ parseData?: object | null
189
189
  }
190
190
 
191
191
  /**
@@ -375,13 +375,12 @@ export async function tcpWhois(domain: string, queryOptions: string, server: str
375
375
  * @param domain Domain name
376
376
  * @param parse Whether the raw text needs to be parsed/formatted or not
377
377
  * @param options {@link WhoIsOptions}
378
- * @returns {@link WhoIsResponse}
378
+ * @returns {@link WhoIsResponse} Returns a {@link WhoIsResponse} object which contains the raw text and parsed data (if parse is true)
379
379
  */
380
380
  export async function whois(domain: string, parse: boolean = false, options: WhoIsOptions | null = null): Promise<WhoIsResponse> {
381
381
  let tld: string
382
382
  let port = 43
383
383
  let server = ''
384
- let queryOptions: string
385
384
  let proxy: ProxyData | null
386
385
  let encoding = 'utf-8'
387
386
 
@@ -398,17 +397,20 @@ export async function whois(domain: string, parse: boolean = false, options: Who
398
397
  }
399
398
 
400
399
  if (server === '') {
401
- let serverData = getWhoIsServer(tld)
400
+ let serverData = getWhoIsServer(tld as keyof typeof SERVERS)
402
401
  if (!serverData) {
402
+ // eslint-disable-next-line no-console
403
403
  console.debug(`No WhoIs server found for TLD: ${tld}! Attempting IANA WhoIs database for server!`)
404
404
  serverData = await findWhoIsServer(tld)
405
405
  if (!serverData) {
406
+ // eslint-disable-next-line no-console
406
407
  console.debug('WhoIs server could not be found!')
407
408
  return {
408
409
  _raw: '',
409
410
  parsedData: null,
410
411
  }
411
412
  }
413
+ // eslint-disable-next-line no-console
412
414
  console.debug(`WhoIs sever found for ${tld}: ${server}`)
413
415
  }
414
416
 
@@ -416,7 +418,7 @@ export async function whois(domain: string, parse: boolean = false, options: Who
416
418
  }
417
419
 
418
420
  const qOptions = getParameters(server)
419
- queryOptions = qOptions || ''
421
+ const queryOptions = qOptions || ''
420
422
 
421
423
  try {
422
424
  const rawData = await tcpWhois(domain, queryOptions, server, port, encoding, proxy)
@@ -488,7 +490,7 @@ export async function batchWhois(domains: string[], parallel: boolean = false, t
488
490
  }
489
491
  else {
490
492
  for (let i = 0; i < domains.length; i++) {
491
- const res = await whois(domains[i], parse, options)
493
+ const res = await whois(domains[i]!, parse, options)
492
494
  response.push(res)
493
495
  }
494
496
  }
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@stacksjs/x-ray",
3
3
  "type": "module",
4
- "version": "0.58.28",
4
+ "version": "0.58.30",
5
5
  "description": "All you need to debug, log & analyze.",
6
6
  "author": "Chris Breuer",
7
7
  "license": "MIT",
@@ -0,0 +1,51 @@
1
+ # zsh-buddy
2
+
3
+ This package contains the zsh-buddy plugin.
4
+
5
+ ## ☘️ Features
6
+
7
+ - ...
8
+
9
+ ## 🤖 Usage
10
+
11
+ ...
12
+
13
+ To view the full documentation, please visit [https://stacksjs.org/ui](https://stacksjs.org/zsh).
14
+
15
+ ## 🧪 Testing
16
+
17
+ ```bash
18
+ # wip
19
+ ```
20
+
21
+ ## 📈 Changelog
22
+
23
+ Please see our [releases](https://github.com/stacksjs/stacks/releases) page for more information on what has changed recently.
24
+
25
+ ## 🚜 Contributing
26
+
27
+ Please review the [Contributing Guide](https://github.com/stacksjs/contributing) for details.
28
+
29
+ ## 🏝 Community
30
+
31
+ For help, discussion about best practices, or any other conversation that would benefit from being searchable:
32
+
33
+ [Discussions on GitHub](https://github.com/stacksjs/stacks/discussions)
34
+
35
+ For casual chit-chat with others using this package:
36
+
37
+ [Join the Stacks Discord Server](https://discord.gg/stacksjs)
38
+
39
+ ## 🙏🏼 Credits
40
+
41
+ Many thanks to the following core technologies & people who have contributed to this plugin:
42
+
43
+ - [Jess Archer](https://github.com/jessarcher/zsh-artisan/blob/master/artisan.plugin.zsh)
44
+ - [Chris Breuer](https://github.com/chrisbbreuer)
45
+ - [All Contributors](../../contributors)
46
+
47
+ ## 📄 License
48
+
49
+ The MIT License (MIT). Please see [LICENSE](https://github.com/stacksjs/stacks/tree/main/LICENSE.md) for more information.
50
+
51
+ Made with 💙
@@ -0,0 +1,29 @@
1
+ {
2
+ "name": "zsh-buddy",
3
+ "type": "module",
4
+ "version": "0.58.30",
5
+ "description": "A better Stacks zsh experience.",
6
+ "author": "Chris Breuer",
7
+ "license": "MIT",
8
+ "funding": "https://github.com/sponsors/chrisbbreuer",
9
+ "homepage": "https://github.com/stacksjs/stacks/tree/main/storage/framework/core/ui#readme",
10
+ "repository": {
11
+ "type": "git",
12
+ "url": "git+https://github.com/stacksjs/stacks.git",
13
+ "directory": "./storage/framework/core/ui"
14
+ },
15
+ "bugs": {
16
+ "url": "https://github.com/stacksjs/stacks/issues"
17
+ },
18
+ "keywords": [
19
+ "ohmyzsh",
20
+ "zsh",
21
+ "stacks"
22
+ ],
23
+ "contributors": [
24
+ "Chris Breuer <chris@stacksjs.org>"
25
+ ],
26
+ "files": [
27
+ "buddy.plugin.zsh"
28
+ ]
29
+ }