@stacksjs/types 0.52.10 → 0.56.3

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 (81) hide show
  1. package/dist/index.d.ts +2111 -39
  2. package/dist/index.mjs +112 -39
  3. package/package.json +24 -18
  4. package/dist/app.d.ts +0 -108
  5. package/dist/app.mjs +0 -0
  6. package/dist/auto-imports.d.ts +0 -1
  7. package/dist/auto-imports.mjs +0 -0
  8. package/dist/build.d.ts +0 -2
  9. package/dist/build.mjs +0 -0
  10. package/dist/cache.d.ts +0 -69
  11. package/dist/cache.mjs +0 -0
  12. package/dist/cdn.d.ts +0 -15
  13. package/dist/cdn.mjs +0 -0
  14. package/dist/cli.d.ts +0 -280
  15. package/dist/cli.mjs +0 -88
  16. package/dist/components.d.ts +0 -60
  17. package/dist/components.mjs +0 -0
  18. package/dist/cron-jobs.d.ts +0 -16
  19. package/dist/cron-jobs.mjs +0 -0
  20. package/dist/database.d.ts +0 -32
  21. package/dist/database.mjs +0 -0
  22. package/dist/debug.d.ts +0 -6
  23. package/dist/debug.mjs +0 -0
  24. package/dist/deploy.d.ts +0 -9
  25. package/dist/deploy.mjs +0 -0
  26. package/dist/dns.d.ts +0 -43
  27. package/dist/dns.mjs +0 -0
  28. package/dist/docs.d.ts +0 -3
  29. package/dist/docs.mjs +0 -0
  30. package/dist/errors.d.ts +0 -1
  31. package/dist/errors.mjs +0 -6
  32. package/dist/events.d.ts +0 -22
  33. package/dist/events.mjs +0 -0
  34. package/dist/exit-code.d.ts +0 -10
  35. package/dist/exit-code.mjs +0 -6
  36. package/dist/fs.d.ts +0 -22
  37. package/dist/fs.mjs +0 -0
  38. package/dist/git.d.ts +0 -128
  39. package/dist/git.mjs +0 -0
  40. package/dist/hashing.d.ts +0 -102
  41. package/dist/hashing.mjs +0 -0
  42. package/dist/i18n.d.ts +0 -19
  43. package/dist/i18n.mjs +0 -0
  44. package/dist/inspect.d.ts +0 -9
  45. package/dist/inspect.mjs +0 -0
  46. package/dist/layout.d.ts +0 -7
  47. package/dist/layout.mjs +0 -0
  48. package/dist/library.d.ts +0 -132
  49. package/dist/library.mjs +0 -0
  50. package/dist/manifest.d.ts +0 -9
  51. package/dist/manifest.mjs +0 -0
  52. package/dist/markdown.d.ts +0 -167
  53. package/dist/markdown.mjs +0 -0
  54. package/dist/model.d.ts +0 -41
  55. package/dist/model.mjs +0 -0
  56. package/dist/notifications.d.ts +0 -164
  57. package/dist/notifications.mjs +0 -0
  58. package/dist/pages.d.ts +0 -10
  59. package/dist/pages.mjs +0 -0
  60. package/dist/payments.d.ts +0 -59
  61. package/dist/payments.mjs +0 -0
  62. package/dist/promise.d.ts +0 -1
  63. package/dist/promise.mjs +0 -0
  64. package/dist/pwa.d.ts +0 -7
  65. package/dist/pwa.mjs +0 -0
  66. package/dist/reactivity.d.ts +0 -1
  67. package/dist/reactivity.mjs +0 -0
  68. package/dist/router.d.ts +0 -42
  69. package/dist/router.mjs +0 -0
  70. package/dist/search-engine.d.ts +0 -143
  71. package/dist/search-engine.mjs +0 -0
  72. package/dist/ssg.d.ts +0 -2
  73. package/dist/ssg.mjs +0 -0
  74. package/dist/stacks.d.ts +0 -163
  75. package/dist/stacks.mjs +0 -0
  76. package/dist/tables.d.ts +0 -52
  77. package/dist/tables.mjs +0 -0
  78. package/dist/ui.d.ts +0 -180
  79. package/dist/ui.mjs +0 -0
  80. package/dist/utils.d.ts +0 -30
  81. package/dist/utils.mjs +0 -0
package/dist/index.d.ts CHANGED
@@ -1,39 +1,2111 @@
1
- export * from './app';
2
- export * from './auto-imports';
3
- export * from './build';
4
- export * from './cache';
5
- export * from './cdn';
6
- export * from './cli';
7
- export * from './components';
8
- export * from './cron-jobs';
9
- export * from './database';
10
- export * from './debug';
11
- export * from './deploy';
12
- export * from './dns';
13
- export * from './docs';
14
- export * from './errors';
15
- export * from './events';
16
- export * from './exit-code';
17
- export * from './fs';
18
- export * from './git';
19
- export * from './hashing';
20
- export * from './i18n';
21
- export * from './inspect';
22
- export * from './layout';
23
- export * from './library';
24
- export * from './manifest';
25
- export * from './markdown';
26
- export * from './model';
27
- export * from './notifications';
28
- export * from './pages';
29
- export * from './payments';
30
- export * from './promise';
31
- export * from './pwa';
32
- export * from './reactivity';
33
- export * from './router';
34
- export * from './search-engine';
35
- export * from './ssg';
36
- export * from './stacks';
37
- export * from './tables';
38
- export * from './ui';
39
- export * from './utils';
1
+ export { Options as AutoImportsOptions } from 'unplugin-auto-import/types';
2
+ export { UserConfig as ViteConfig } from 'vite';
3
+ import { ViteSSGContext } from 'vite-ssg';
4
+ export { ViteSSGContext } from 'vite-ssg';
5
+ import { Ora } from 'ora';
6
+ export { Ora as SpinnerOptions } from 'ora';
7
+ import { ExecaReturnValue } from 'execa';
8
+ import { Ok, Err } from 'neverthrow';
9
+ export { Err, Ok, Result, ResultAsync } from 'neverthrow';
10
+ import { VineString, VineNumber, VineBoolean } from '@vinejs/vine';
11
+ import { Settings, MeiliSearch, IndexOptions, EnqueuedTask, Index, IndexesResults, DocumentOptions, SearchParams, Hits, SearchResponse } from 'meilisearch';
12
+ export { EnqueuedTask, Hits, Index, IndexOptions, IndexesResults, MeiliSearch, DocumentOptions as RecordOptions, Settings as SearchEngineSettings, SearchParams, SearchResponse } from 'meilisearch';
13
+ import { UserConfig } from 'vitepress';
14
+ import { Options } from 'vite-plugin-inspect';
15
+ import { UserOptions } from 'vite-plugin-vue-layouts';
16
+ import { Dinero } from '@stacksjs/utils';
17
+ import { IEmailOptions } from '@novu/stateless';
18
+ export { IChatOptions as ChatOptions, ISendMessageSuccessResponse as SendMessageSuccessResponse, ISmsOptions as SmsOptions } from '@novu/stateless';
19
+ import { Options as Options$1 } from 'vite-plugin-pwa';
20
+ export { Ref } from 'vue';
21
+ import { UserShortcuts } from 'unocss';
22
+ export { CAC as CLI } from 'cac';
23
+ export { Options as ComponentOptions } from 'unplugin-vue-components';
24
+
25
+ /**
26
+ * **Application Options**
27
+ *
28
+ * This configuration defines all of your application options. Because Stacks is fully-typed,
29
+ * you may hover any of the options below and the definitions will be provided. In case
30
+ * you have any questions, feel free to reach out via Discord or GitHub Discussions.
31
+ */
32
+ interface AppOptions {
33
+ /**
34
+ * **Application Name**
35
+ *
36
+ * This value is the name of your application. This value is used when the
37
+ * framework needs to place the application's name in a log or any
38
+ * other location as required by the application or its packages.
39
+ *
40
+ * @default string "Stacks"
41
+ */
42
+ name: string;
43
+ /**
44
+ * **Application Environment**
45
+ *
46
+ * This value determines the "environment" your application is currently
47
+ * running in. This may determine how you prefer to configure various
48
+ * services the application utilizes. Set this in your ".env" file
49
+ *
50
+ * @default "local"
51
+ */
52
+ env: 'local' | 'development' | 'staging' | 'production';
53
+ /**
54
+ * **Application URL**
55
+ *
56
+ * This URL is used by the console to properly generate URLs when using
57
+ * the Buddy command line tool. You should set this to the root of
58
+ * your application so that it is used when running Buddy tasks.
59
+ *
60
+ * @default string "https://stacks.test"
61
+ * @example "https://my-project.test"
62
+ */
63
+ url: string;
64
+ /**
65
+ * **Application Debug Mode**
66
+ *
67
+ * When your application is in debug mode, detailed error messages with
68
+ * stack traces will be shown on every error that occurs within your
69
+ * application. If disabled, a simple generic error page is shown.
70
+ *
71
+ * @default true
72
+ */
73
+ debug: boolean;
74
+ /**
75
+ * **Application Port**
76
+ *
77
+ * This port is used when Stacks creates a server you. You should set
78
+ * a port that's not already in use by your machine. Stacks defaults
79
+ * to a memorable port that likely is free on your end: 3333.
80
+ *
81
+ * @default number 3333
82
+ */
83
+ port: number;
84
+ /**
85
+ * **Encryption Key**
86
+ *
87
+ * This key is used by the Stacks encrypter service and should be set to
88
+ * a random, 32 character string, otherwise these encrypted strings will
89
+ * not be safe. Please do this before deploying an application!
90
+ */
91
+ key?: string;
92
+ /**
93
+ * **Application Timezone**
94
+ *
95
+ * Here you may specify the default timezone for your application, which
96
+ * will be used by Stacks and date-time functions. We have gone ahead
97
+ * and set this to a sensible default for you out of the box.
98
+ *
99
+ * @default string "UTC"
100
+ */
101
+ timezone?: string;
102
+ /**
103
+ * **Application Locale Configuration**
104
+ *
105
+ * The application locale determines the default locale that will be used
106
+ * by the translation service provider. You are free to set this value
107
+ * to any of the locales which will be supported by the application.
108
+ *
109
+ * @default string "en"
110
+ * @example
111
+ * de // ./lang/de.yml needs to be present for this
112
+ */
113
+ locale?: string;
114
+ /**
115
+ * **Application Fallback Locale**
116
+ *
117
+ * The fallback locale determines the locale to use when the current one
118
+ * is not available. You may change the value to correspond to any of
119
+ * the language folders that are provided through your application.
120
+ *
121
+ * @default string "en"
122
+ */
123
+ fallbackLocale: 'en';
124
+ /**
125
+ * **Cipher**
126
+ *
127
+ * Description WIP.
128
+ *
129
+ * @default string "aes-256-cbc"
130
+ */
131
+ cipher: string;
132
+ }
133
+
134
+ interface CacheOptions {
135
+ /**
136
+ * **Cache Driver**
137
+ *
138
+ * This value determines the cache driver that will be used by your application to store
139
+ * cached data. By default, Stacks uses the "redis" driver, which stores cached data in
140
+ * in a self-configufed Redis instance. You may use any of the other drivers provided
141
+ * by Stacks or write your own custom driver.
142
+ *
143
+ * @default "redis"
144
+ * @example "redis"
145
+ * @example "memcached"
146
+ * @example "dynamodb"
147
+ *
148
+ * @see https://stacks.js.org/docs/cache
149
+ */
150
+ driver: string;
151
+ /**
152
+ * **Cache Prefix**
153
+ *
154
+ * This value determines the prefix that will be used when storing items in the cache. This
155
+ * prefix may be useful when multiple applications are sharing the same cache driver so that
156
+ * they may avoid collisions when attempting to retrieve items from the cache.
157
+ *
158
+ * @default string "stacks"
159
+ * @example "stacks"
160
+ *
161
+ * @see https://stacks.js.org/docs/cache
162
+ */
163
+ prefix: string;
164
+ /**
165
+ * **Cache TTL**
166
+ *
167
+ * This value determines the default time to live for items stored in the cache. This value
168
+ * may be overridden when storing items in the cache. If no value is specified, the cache
169
+ * driver will default to a reasonable time to live for the given item.
170
+ *
171
+ * @default number 3600
172
+ * @example 3600
173
+ * @example 3600 * 24
174
+ * @example -1 (never expires)
175
+ */
176
+ ttl: number;
177
+ drivers: {
178
+ redis?: {
179
+ connection: string;
180
+ /**
181
+ * **Redis Host**
182
+ *
183
+ * This value determines the host that will be used to connect to the Redis server.
184
+ *
185
+ * @default string "localhost"
186
+ * @example "localhost"
187
+ */
188
+ host: string;
189
+ /**
190
+ * **Redis Port**
191
+ *
192
+ * This value determines the port that will be used to connect to the Redis server.
193
+ *
194
+ * @default number 6379
195
+ * @example 6379
196
+ */
197
+ port: number;
198
+ };
199
+ memcached?: {};
200
+ dynamodb?: {};
201
+ };
202
+ }
203
+
204
+ interface CdnOptions {
205
+ /**
206
+ * **CDN Driver**
207
+ *
208
+ * This value determines the default CDN driver that will be used when interacting with the
209
+ * CDN service. This value may be overridden when interacting with the CDN service.
210
+ *
211
+ * @default "cloudfront"
212
+ * @example "cloudfront"
213
+ * @example "fastly" wip
214
+ *
215
+ * @see https://stacks.js.org/docs/cdn
216
+ */
217
+ driver: string;
218
+ }
219
+
220
+ declare class ValidationError extends Error {
221
+ messages: any;
222
+ status: number;
223
+ code: string;
224
+ constructor(messages: any, options?: ErrorOptions);
225
+ get [Symbol.toStringTag](): string;
226
+ toString(): string;
227
+ }
228
+ type StacksError = Error | ValidationError;
229
+
230
+ /**
231
+ * The parsed command-line arguments
232
+ */
233
+
234
+ type CommandReturnValue = ExecaReturnValue<string>;
235
+ type CommandResult = Ok<ExecaReturnValue<string>, Error | void> | Err<ExecaReturnValue<string>, Error | string | void>;
236
+ interface OutroOptions extends CliOptions {
237
+ type?: 'success' | 'error' | 'warning' | 'info';
238
+ startTime?: number;
239
+ useSeconds?: boolean;
240
+ isError?: boolean;
241
+ quiet?: boolean;
242
+ }
243
+ interface IntroOptions {
244
+ /**
245
+ * @default true
246
+ */
247
+ showPerformance?: boolean;
248
+ /**
249
+ * @default false
250
+ */
251
+ quiet: boolean;
252
+ }
253
+ type SpinnerOptions = Ora;
254
+ type CliOptionsKeys = keyof CliOptions;
255
+ /**
256
+ * The CLI Options used in `./config/cli.ts`.
257
+ */
258
+ interface UserCliOptions {
259
+ name?: string;
260
+ command?: string;
261
+ description?: string;
262
+ }
263
+ /**
264
+ * The options to pass to the CLI.
265
+ */
266
+ interface CliOptions {
267
+ /**
268
+ * **Quiet Output**
269
+ *
270
+ * When your application is in "quiet"-mode, a different level of information
271
+ * like useful outputs for debugging reasons, will be shown.
272
+ * When disabled, it defaults to the "normal experience."
273
+ *
274
+ * @default false
275
+ */
276
+ quiet?: boolean;
277
+ /**
278
+ * **Verbose Output**
279
+ *
280
+ * When your application is in "verbose"-mode, a different level of,
281
+ * information like useful outputs for debugging reasons, will be
282
+ * shown. When disabled, it defaults to the "normal experience."
283
+ *
284
+ * @default false
285
+ */
286
+ verbose?: boolean;
287
+ /**
288
+ * **Current Work Directory**
289
+ *
290
+ * Based on the `cwd` value, that's where the command...
291
+ *
292
+ * @default projectPath()
293
+ */
294
+ cwd?: string;
295
+ /**
296
+ * **Should show loading animation spinner?**
297
+ *
298
+ * Should the command show a loading animation?
299
+ * Please note, when debug mode is enabled,
300
+ * the animation will not show.
301
+ *
302
+ * @default true
303
+ */
304
+ showSpinner?: boolean | SpinnerOptions;
305
+ /**
306
+ * **Spinner Text**
307
+ *
308
+ * The text to show when the spinner is shown.
309
+ *
310
+ * @default 'Executing...'
311
+ */
312
+ spinnerText?: string;
313
+ /**
314
+ * **Should the command be run inside a shell?**
315
+ *
316
+ * If `true`, runs `command` inside of a shell. Uses `/bin/sh` on UNIX and `cmd.exe`
317
+ * on Windows. A different shell can be specified as a string. The shell should
318
+ * understand the `-c` switch on UNIX or `/d /s /c` on Windows.
319
+ *
320
+ * We recommend against using this option since it is:
321
+ * - not cross-platform, encouraging shell-specific syntax.
322
+ * - slower, because of the additional shell interpretation.
323
+ * - unsafe, potentially allowing command injection.
324
+ *
325
+ * @default false
326
+ */
327
+ shell?: boolean;
328
+ /**
329
+ * **Encoding**
330
+ *
331
+ * Encoding type
332
+ *
333
+ * @default 'utf-8'
334
+ */
335
+ encoding?: string;
336
+ }
337
+
338
+ type ActionOption = 'types';
339
+ /**
340
+ * The options to pass to the Action.
341
+ */
342
+ type ActionOptions = {
343
+ [key in ActionOption]?: boolean;
344
+ } & CliOptions;
345
+ type BuildOption = 'components' | 'vueComponents' | 'webComponents' | 'elements' | 'functions' | 'docs' | 'pages' | 'stacks' | 'all';
346
+ type BuildOptions = {
347
+ [key in BuildOption]: boolean;
348
+ } & CliOptions;
349
+ type AddOption = 'table' | 'calendar' | 'all';
350
+ type AddOptions = {
351
+ [key in AddOption]?: boolean;
352
+ } & CliOptions;
353
+ type CreateStringOption = 'name';
354
+ type CreateBooleanOption = 'ui' | 'components' | 'web-components' | 'vue' | 'pages' | 'functions' | 'api' | 'database';
355
+ type CreateOptions = {
356
+ [key in CreateBooleanOption]: boolean;
357
+ } & {
358
+ [key in CreateStringOption]: string;
359
+ } & CliOptions;
360
+ type DevOption = 'components' | 'docs' | 'pages' | 'functions' | 'desktop' | 'all';
361
+ type DevOptions = {
362
+ [key in DevOption]: boolean;
363
+ } & CliOptions;
364
+ type GeneratorOption = 'types' | 'entries' | 'webTypes' | 'customData' | 'ideHelpers' | 'vueCompatibility' | 'componentMeta';
365
+ type GeneratorOptions = {
366
+ [key in GeneratorOption]?: boolean;
367
+ } & CliOptions;
368
+ type LintOption = 'fix';
369
+ type LintOptions = {
370
+ [key in LintOption]: boolean;
371
+ } & CliOptions;
372
+ type MakeStringOption = 'name' | 'chat' | 'sms' | 'env';
373
+ type MakeBooleanOption = 'component' | 'page' | 'function' | 'language' | 'database' | 'migration' | 'factory' | 'notification' | 'stack';
374
+ type MakeOptions = {
375
+ [key in MakeBooleanOption]: boolean;
376
+ } & {
377
+ [key in MakeStringOption]: string;
378
+ } & CliOptions;
379
+ type UpgradeBoolean = 'framework' | 'dependencies' | 'packageManager' | 'node' | 'all' | 'force';
380
+ type UpgradeString = 'version';
381
+ type UpgradeOptions = {
382
+ [key in UpgradeBoolean]: boolean;
383
+ } & {
384
+ [key in UpgradeString]: string;
385
+ } & CliOptions;
386
+ type ExamplesString = 'version';
387
+ type ExamplesBoolean = 'components' | 'vue' | 'webComponents' | 'elements' | 'all' | 'force';
388
+ type ExamplesOption = ExamplesString & ExamplesBoolean | void;
389
+ type ExamplesOptions = {
390
+ [key in ExamplesString]: string;
391
+ } & {
392
+ [key in ExamplesBoolean]: boolean;
393
+ } & CliOptions;
394
+ type TestOptions = CliOptions & {
395
+ showReport?: boolean;
396
+ };
397
+ interface CleanOptions extends CliOptions {
398
+ }
399
+ interface CommitOptions extends CliOptions {
400
+ }
401
+ interface KeyOptions extends CliOptions {
402
+ }
403
+ interface FreshOptions extends CliOptions {
404
+ }
405
+ interface InspireOptions extends CliOptions {
406
+ }
407
+ interface ReleaseOptions extends CliOptions {
408
+ }
409
+ interface PreinstallOptions extends CliOptions {
410
+ }
411
+ interface PrepublishOptions extends CliOptions {
412
+ }
413
+ interface TinkerOptions extends CliOptions {
414
+ }
415
+ interface TypesOptions extends CliOptions {
416
+ }
417
+ type LibEntryType = 'vue-components' | 'web-components' | 'functions' | 'all';
418
+ /**
419
+ * The available npm scripts within the Stacks toolkit.
420
+ */
421
+ declare const enum NpmScript {
422
+ Build = "build",
423
+ BuildComponents = "vite build --config ./core/build/src/vue-components.ts",
424
+ BuildWebComponents = "build:web-components",
425
+ BuildFunctions = "build:functions",
426
+ BuildDocs = "build:docs",
427
+ BuildStacks = "build:stacks",
428
+ Clean = "rimraf pnpm-lock.yaml node_modules/ .stacks/**/node_modules .stacks/**/dist",
429
+ Dev = "dev",
430
+ DevComponents = "vite --config ./core/build/src/vue-components.ts",
431
+ DevDocs = "npx vitepress dev ./docs/src",
432
+ DevDesktop = "dev:desktop",
433
+ DevPages = "dev:pages",
434
+ DevFunctions = "dev:functions",
435
+ Fresh = "fresh",
436
+ Lint = "eslint .",
437
+ LintFix = "eslint . --fix",
438
+ LintPackageJson = "npx publint",
439
+ MakeStack = "make:stack",
440
+ Test = "vitest --config vitest.config.ts",
441
+ TestUnit = "vitest --config vitest.config.ts",
442
+ TestFeature = "playwright test --config playwright.config.ts",
443
+ TestUi = "vitest --config vitest.config.ts --ui",
444
+ TestCoverage = "vitest --config vitest.config.ts --coverage",
445
+ TestTypes = "vue-npx tsc --noEmit",
446
+ Generate = "generate",
447
+ GenerateTypes = "generate:types",
448
+ GenerateEntries = "generate:entries",
449
+ GenerateVueCompat = "generate:vue-compatibility",
450
+ GenerateWebTypes = "generate:web-types",
451
+ GenerateVsCodeCustomData = "generate:vscode-custom-data",
452
+ GenerateIdeHelpers = "generate:ide-helpers",
453
+ GenerateComponentMeta = "generate:component-meta",
454
+ Release = "release",
455
+ Commit = "commit",
456
+ Example = "example",
457
+ ExampleVue = "example:vue",
458
+ ExampleWebComponents = "example:web-components",
459
+ KeyGenerate = "key:generate",
460
+ TypesFix = "types:fix",
461
+ TypesGenerate = "types:generate",
462
+ Preinstall = "preinstall",
463
+ Prepublish = "prepublish",
464
+ Wip = "wip",
465
+ UpgradeNode = "./.stacks/scripts/setup.sh +nodejs.org",
466
+ UpgradeDependencies = "pnpm up"
467
+ }
468
+ declare const enum Action {
469
+ Bump = "bump",
470
+ BuildStacks = "build/stacks",
471
+ BuildComponentLibs = "build/component-libs",
472
+ BuildVueComponentLib = "build-vue-component-lib",
473
+ BuildWebComponentLib = "build-web-component-lib",
474
+ BuildCli = "build-cli",
475
+ BuildCore = "build/core",
476
+ BuildDocs = "build-docs",
477
+ BuildFunctionLib = "build-function-lib",
478
+ Changelog = "changelog",
479
+ Clean = "clean",
480
+ DevComponents = "dev/components",
481
+ Dev = "dev/index",
482
+ DevDocs = "dev/docs",
483
+ Deploy = "deploy",
484
+ Fresh = "fresh",
485
+ GenerateLibraryEntries = "generate/lib-entries",
486
+ Inspire = "inspire",
487
+ KeyGenerate = "key-generate",
488
+ MakeNotification = "make-notification",
489
+ Migrate = "migrate",
490
+ Seed = "seed",
491
+ Lint = "lint/index",
492
+ LintFix = "lint/fix",
493
+ Prepublish = "prepublish",
494
+ Release = "release",
495
+ ShowFeatureTestReport = "show-feature-test-report",
496
+ Test = "test",
497
+ TestUi = "test-ui",
498
+ TestUnit = "test-unit",
499
+ TestFeature = "test-feature",
500
+ TestCoverage = "test-coverage",
501
+ Tinker = "tinker",
502
+ Typecheck = "typecheck",
503
+ Upgrade = "upgrade/index",
504
+ UpgradeNode = "upgrade/node",
505
+ UpgradePackageManager = "upgrade/package-manager"
506
+ }
507
+
508
+ interface TagOption {
509
+ /**
510
+ * **Tag Name**
511
+ *
512
+ * This is the name of the component to be included in your library build.
513
+ * When defining a tag, ensure that the name corresponds to a file within
514
+ * root component directory.
515
+ *
516
+ * @example
517
+ * {
518
+ * tags: [{
519
+ * name: 'HelloWorld' // results in `<HelloWorld />`
520
+ * }]
521
+ * }
522
+ *
523
+ * @example
524
+ * {
525
+ * tags: [{
526
+ * name: ['HelloWorld', 'AppHelloWorld'] // results in `<AppHelloWorld />`
527
+ * }]
528
+ * }
529
+ * @see https://stacksjs.dev/docs/components
530
+ */
531
+ name: string | string[];
532
+ /**
533
+ * **Tag Description**
534
+ *
535
+ * This is the description of your component. This value is
536
+ * used when to provide additional information to IDEs.
537
+ *
538
+ * @example
539
+ * {
540
+ * name: 'HelloWorld' // results in `<HelloWorld />`
541
+ * }
542
+ * @see https://stacksjs.dev/docs/components
543
+ */
544
+ description?: string;
545
+ /**
546
+ * **Tag Attributes**
547
+ *
548
+ * These are your component's attributes. While it's an optional field, you should aim
549
+ * to define all of your component attributes here, to provide as much context
550
+ * to your IDEs as possible, when actually using the library as an end-user.
551
+ *
552
+ * @example
553
+ * {
554
+ * attributes: {
555
+ * name: 'greeting',
556
+ * description: 'The way to greet the user.',
557
+ * }
558
+ * }
559
+ * @see https://stacksjs.dev/docs/components
560
+ */
561
+ attributes?: {
562
+ name: string;
563
+ description: string;
564
+ }[];
565
+ }
566
+ type TagsOptions = TagOption[];
567
+
568
+ /**
569
+ * Cron Job Options.
570
+ */
571
+ interface JobOptions {
572
+ /**
573
+ * The name of the job.
574
+ */
575
+ name?: string;
576
+ action?: string | Function;
577
+ run?: string | Function;
578
+ schedule?: string;
579
+ description?: string;
580
+ enabled?: boolean;
581
+ timezone?: string;
582
+ active?: boolean;
583
+ tries?: number;
584
+ backoff?: number | number[];
585
+ }
586
+ type Job = JobOptions;
587
+ type Jobs = Job[];
588
+ interface CronJobOptions extends Omit<JobOptions, 'schedule'> {
589
+ schedule: string;
590
+ }
591
+ type CronJob = CronJobOptions;
592
+ type CronJobs = CronJob[];
593
+ declare enum Every {
594
+ Minute = "* * * * *",
595
+ Hour = "0 * * * *",
596
+ HalfHour = "0,30 * * * *",
597
+ Day = "0 0 * * *",
598
+ Month = "0 0 1 * *",
599
+ Week = "0 0 * * 0",
600
+ Year = "0 0 1 1 *",
601
+ FifthMinute = "*/5 * * * *",
602
+ TenthMinute = "*/10 * * * *"
603
+ }
604
+
605
+ interface AuthOptions {
606
+ }
607
+ interface SeedOptions {
608
+ count: number;
609
+ }
610
+ interface TimestampOptions {
611
+ createdAt?: string;
612
+ updatedAt?: string;
613
+ deletedAt?: string;
614
+ }
615
+ interface Base {
616
+ }
617
+ /**
618
+ * Model.
619
+ */
620
+ interface Model extends Base {
621
+ name?: string;
622
+ table?: string;
623
+ fields: Fields;
624
+ hasOne?: string;
625
+ hasMany?: string;
626
+ belongsToMany?: string;
627
+ hasThrough?: {
628
+ model: string;
629
+ through: string;
630
+ using: string;
631
+ };
632
+ authenticatable?: boolean | AuthOptions;
633
+ seedable?: boolean | SeedOptions;
634
+ searchable?: boolean | Settings;
635
+ useSeed?: boolean | SeedOptions;
636
+ useSearch?: boolean | Settings;
637
+ useSearchEngine?: boolean | Settings;
638
+ useTimestamps?: boolean | TimestampOptions;
639
+ }
640
+ interface Fields {
641
+ [key: string]: {
642
+ default?: boolean;
643
+ unique?: boolean;
644
+ required?: boolean;
645
+ factory?: () => any;
646
+ validator?: {
647
+ rule: VineString | VineNumber | VineBoolean | Date | Nullable<any>;
648
+ message: string;
649
+ };
650
+ };
651
+ }
652
+
653
+ type DatabaseClient = any;
654
+ interface DatabaseOptions {
655
+ default: string;
656
+ connections: {
657
+ mysql: {
658
+ url?: string;
659
+ host?: string;
660
+ port?: number;
661
+ client?: DatabaseClient;
662
+ name?: string;
663
+ username?: string;
664
+ password?: string;
665
+ prefix?: string;
666
+ };
667
+ sqlite: {
668
+ url?: string;
669
+ database?: string;
670
+ prefix?: string;
671
+ };
672
+ planetscale: {};
673
+ postgres: {};
674
+ };
675
+ migrations: string;
676
+ }
677
+ interface FactoryOptions {
678
+ name: string;
679
+ count?: number;
680
+ items: object;
681
+ columns: object;
682
+ }
683
+ interface SchemaOptions {
684
+ database: string;
685
+ }
686
+ interface DatabaseDriver {
687
+ client: DatabaseClient;
688
+ migrate: (models: Model[], path: string, options?: SchemaOptions) => Promise<void>;
689
+ factory: (modelName: string, fileName: string, path: string) => Promise<void>;
690
+ }
691
+
692
+ interface DebugOptions {
693
+ driver?: string;
694
+ enabled: boolean;
695
+ host: string;
696
+ port: number;
697
+ }
698
+
699
+ /**
700
+ * **Deploy Options**
701
+ *
702
+ * This configuration defines all of your deployment options. Because Stacks is fully-typed,
703
+ * you may hover any of the options below and the definitions will be provided. In case
704
+ * you have any questions, feel free to reach out via Discord or GitHub Discussions.
705
+ */
706
+ interface DeployOptions {
707
+ }
708
+
709
+ interface ARecord {
710
+ name: string | '@' | '*';
711
+ address: string;
712
+ ttl?: number | 'auto';
713
+ }
714
+ interface CNameRecord {
715
+ name: string;
716
+ target: string;
717
+ ttl: number | 'auto';
718
+ }
719
+ interface MXRecord {
720
+ name: string | '@';
721
+ mailServer: string;
722
+ ttl: number | 'auto';
723
+ priority: number;
724
+ }
725
+ interface TxtRecord {
726
+ name: string | '@';
727
+ ttl: number | 'auto';
728
+ content: string;
729
+ }
730
+ interface AAAARecord {
731
+ name: string | '@' | '*';
732
+ address: string;
733
+ ttl: number | 'auto';
734
+ }
735
+ type DnsRecord = ARecord | CNameRecord | MXRecord | TxtRecord | AAAARecord;
736
+ /**
737
+ * **DNS Options**
738
+ *
739
+ * This configuration defines all of your DNS options. Because Stacks is fully-typed,
740
+ * you may hover any of the options below and the definitions will be provided. In case
741
+ * you have any questions, feel free to reach out via Discord or GitHub Discussions.
742
+ *
743
+ * @see https://stacksjs.dev/docs/dns
744
+ */
745
+ interface DnsOptions {
746
+ a?: ARecord[];
747
+ aaaa?: AAAARecord[];
748
+ cname?: CNameRecord[];
749
+ mx?: MXRecord[];
750
+ txt?: TxtRecord[];
751
+ }
752
+
753
+ type DocsConfig = UserConfig;
754
+ type DocsOptions = DocsConfig;
755
+
756
+ /**
757
+ * **Events**
758
+ *
759
+ * This configuration defines all of your events. Because Stacks is fully-typed, you may
760
+ * hover any of the options below and the definitions will be provided. In case you
761
+ * have any questions, feel free to reach out via Discord or GitHub Discussions.
762
+ *
763
+ * @example To fire an event, you may use any of the following approaches:
764
+ * ```ts
765
+ * dispatch('user:registered', { name: 'Chris', email: 'chris@stacksjs.dev' })
766
+ *
767
+ * // alternatively, you may use the following:
768
+ * useEvent('user:registered', { name: 'Chris', email: 'chris@stacksjs.dev' })
769
+ * events.emit('user:registered', { name: 'Chris', email: 'chris@stacksjs.dev' })
770
+ * useEvents.emit('user:registered', { name: 'Chris', email: 'chris@stacksjs.dev' })
771
+ * ````
772
+
773
+ * @example To capture an event, you may use any of the following approaches:
774
+ * ```ts
775
+ * listen('user:registered', (user) => sendWelcomeEmail(user))
776
+ *
777
+ * // alternatively, you may use the following:
778
+ * useListen('user:registered', (user) => sendWelcomeEmail(user))
779
+ * events.on('user:registered', (user) => sendWelcomeEmail(user))
780
+ * useEvents.on('user:registered', (user) => sendWelcomeEmail(user))
781
+ * ```
782
+ */
783
+ interface Events {
784
+ [key: string]: (...args: any[]) => Function;
785
+ }
786
+
787
+ /**
788
+ * CLI exit codes.
789
+ *
790
+ * @see https://nodejs.org/api/process.html#process_exit_codes
791
+ */
792
+ declare enum ExitCode {
793
+ Success = 0,
794
+ FatalError = 1,
795
+ InvalidArgument = 9
796
+ }
797
+
798
+ /**
799
+ * Describes a plain-text file.
800
+ */
801
+ interface TextFile {
802
+ path: string;
803
+ data: string;
804
+ }
805
+ /**
806
+ * Describes a JSON file.
807
+ */
808
+ interface JsonFile {
809
+ path: string;
810
+ data: unknown;
811
+ indent: string;
812
+ newline: string | undefined;
813
+ }
814
+ /**
815
+ * Describes a package.json file.
816
+ */
817
+ interface PackageJson {
818
+ engines: {
819
+ node: string;
820
+ pnpm: string;
821
+ };
822
+ version: string;
823
+ packageManager: string;
824
+ }
825
+
826
+ /**
827
+ * **Git Options**
828
+ *
829
+ * This configuration defines all of your git options. Because Stacks is fully-typed, you may
830
+ * hover any of the options below and the definitions will be provided. In case you
831
+ * have any questions, feel free to reach out via Discord or GitHub Discussions.
832
+ */
833
+ interface GitOptions {
834
+ /**
835
+ * **Git Hooks**
836
+ *
837
+ * The git hooks to use.
838
+ *
839
+ * @see https://git-scm.com/docs/githooks
840
+ * @example
841
+ * ```ts
842
+ * git: {
843
+ * hooks: {
844
+ * 'pre-commit': 'lint-staged',
845
+ * }
846
+ * }
847
+ * ```
848
+ */
849
+ hooks: GitHooks;
850
+ /**
851
+ * **Git Commit Scopes**
852
+ *
853
+ * The git commit scopes to use.
854
+ *
855
+ * @see https://stacksjs.dev/docs/git/scopes
856
+ * @example
857
+ * git: [
858
+ * scopes: [
859
+ * '', 'ci', 'deps', 'dx', 'release', 'readme', 'test', 'actions', 'build', 'cli',
860
+ * 'config', 'examples', 'functions', 'modules', 'views', 'router', 'scripts',
861
+ * 'ui', 'utils', 'arrays', 'collections', 'fs', 'objects', 'strings',
862
+ * ]
863
+ * ]
864
+ */
865
+ scopes: string[];
866
+ /**
867
+ * **Git Commit Types**
868
+ *
869
+ * The git commit types to use.
870
+ *
871
+ * @default array
872
+ * @see https://stacksjs.dev/docs/git/types
873
+ * @see https://www.conventionalcommits.org/en/v1.0.0/
874
+ * @example
875
+ * ```ts
876
+ * git: [
877
+ * types: [
878
+ * 'build', 'chore', 'ci', 'docs', 'feat', 'fix', 'perf', 'refactor', 'revert', 'style', 'test',
879
+ * ]
880
+ * ]
881
+ * ```
882
+ */
883
+ types: {
884
+ value: string;
885
+ name: string;
886
+ emoji: string;
887
+ }[];
888
+ /**
889
+ * **Messages—Options**
890
+ *
891
+ * The git messages/prompts to use.
892
+ *
893
+ * @default object
894
+ * @example
895
+ * ```ts
896
+ * messages: {
897
+ * type: 'Select the type of change that you\'re committing:',
898
+ * scope: 'Denote the SCOPE of this change:',
899
+ * subject: 'Write a SHORT, IMPERATIVE tense description of the change:\n',
900
+ * body: 'Provide a LONGER description of the change (optional). Use "|" to break new line:\n',
901
+ * breaking: 'List any BREAKING CHANGES (optional):\n',
902
+ * footer: 'List any ISSUES CLOSED by this change (optional). E.g.: #31, #34:\n',
903
+ * confirmCommit: 'Are you sure you want to proceed with the commit above?',
904
+ * }
905
+ * ```
906
+ * @see https://stacksjs.dev/docs/git/messages
907
+ */
908
+ messages: {
909
+ type: string;
910
+ scope: string;
911
+ customScope: string;
912
+ subject: string;
913
+ body: string;
914
+ breaking: string;
915
+ footerPrefixesSelect: string;
916
+ customFooterPrefixes: string;
917
+ footer: string;
918
+ confirmCommit: string;
919
+ };
920
+ }
921
+ interface Hooks {
922
+ 'applypatch-msg'?: string;
923
+ 'pre-applypatch'?: string;
924
+ 'post-applypatch'?: string;
925
+ 'pre-commit'?: string;
926
+ 'pre-merge-commit'?: string;
927
+ 'prepare-commit-msg'?: string;
928
+ 'commit-msg'?: string;
929
+ 'post-commit'?: string;
930
+ 'pre-rebase'?: string;
931
+ 'post-checkout'?: string;
932
+ 'post-merge'?: string;
933
+ 'pre-push'?: string;
934
+ 'pre-receive'?: string;
935
+ 'update'?: string;
936
+ 'proc-receive'?: string;
937
+ 'post-receive'?: string;
938
+ 'post-update'?: string;
939
+ 'reference-transaction'?: string;
940
+ 'push-to-checkout'?: string;
941
+ 'pre-auto-gc'?: string;
942
+ 'post-rewrite'?: string;
943
+ 'sendemail-validate'?: string;
944
+ 'fsmonitor-watchman'?: string;
945
+ 'p4-changelist'?: string;
946
+ 'p4-prepare-changelist'?: string;
947
+ 'p4-post-changelist'?: string;
948
+ 'p4-pre-submit'?: string;
949
+ 'post-index-change'?: string;
950
+ }
951
+ interface GitHooks extends Hooks {
952
+ }
953
+
954
+ /**
955
+ * The Stacks runtime provides secure Bcrypt & Argon2 hashing for storing user passwords.
956
+ * If you are using one of the Laravel application starter kits, Bcrypt will be used for
957
+ * registration and authentication by default.
958
+ *
959
+ * Bcrypt is a great choice for hashing passwords because its "work factor" is adjustable, which
960
+ * means that the time it takes to generate a hash can be increased as hardware power increases.
961
+ * When hashing passwords, slow is good. The longer an algorithm takes to hash a password, the
962
+ * longer it takes malicious users to generate "rainbow tables" of all possible string hash
963
+ * values that may be used in brute force attacks against applications.
964
+ *
965
+ * @see https://stacksjs.dev/docs/hashing
966
+ */
967
+ interface HashingOptions {
968
+ /**
969
+ * **Hashing Driver**
970
+ *
971
+ * This option controls the default hash driver that will be used to hash
972
+ * passwords for your application. By default, the bcrypt algorithm is
973
+ * used; however, you remain free to modify this option if you wish.
974
+ *
975
+ * @see https://stacksjs.dev/docs/hashing
976
+ */
977
+ driver: 'argon' | 'bcrypt';
978
+ /**
979
+ * **Bcrypt Option**
980
+ *
981
+ * Here you may specify the configuration options that should be used when
982
+ * passwords are hashed using the Bcrypt algorithm. This will allow you
983
+ * to control the amount of time it takes to hash the given password.
984
+ *
985
+ * @see https://stacksjs.dev/docs/hashing
986
+ */
987
+ bcrypt?: BcryptOptions;
988
+ /**
989
+ * **Argon Options**
990
+ *
991
+ * Here you may specify the configuration options that should be used when
992
+ * passwords are hashed using the Argon algorithm. These will allow you
993
+ * to control the amount of time it takes to hash the given password.
994
+ *
995
+ * @see https://stacksjs.dev/docs/hashing
996
+ */
997
+ argon?: ArgonOptions;
998
+ }
999
+ /**
1000
+ * **Bcrypt Options**
1001
+ *
1002
+ * Here you may specify the configuration options that should be used when
1003
+ * passwords are hashed using the Bcrypt algorithm. This will allow you
1004
+ * to control the amount of time it takes to hash the given password.
1005
+ *
1006
+ * @see https://stacksjs.dev/docs/hashing
1007
+ */
1008
+ interface BcryptOptions {
1009
+ /**
1010
+ * Bcrypt salt rounds.
1011
+ *
1012
+ * @default number 10
1013
+ * @see https://stacksjs.dev/docs/hashing
1014
+ */
1015
+ rounds?: number;
1016
+ }
1017
+ /**
1018
+ * **Argon Options**
1019
+ *
1020
+ * Here you may specify the configuration options that should be used when
1021
+ * passwords are hashed using the Argon algorithm. These will allow you
1022
+ * to control the amount of time it takes to hash the given password.
1023
+ *
1024
+ * @see https://stacksjs.dev/docs/hashing
1025
+ */
1026
+ interface ArgonOptions {
1027
+ /**
1028
+ * **Argon Memory**
1029
+ *
1030
+ * Amount of memory (in kibibytes) to use.
1031
+ *
1032
+ * @default number 65536
1033
+ * @see https://stacksjs.dev/docs/hashing
1034
+ */
1035
+ memory?: number;
1036
+ /**
1037
+ * **Argon Parallelism**
1038
+ *
1039
+ * Degree of parallelism (i.e. number of threads).
1040
+ *
1041
+ * @default number 1
1042
+ * @see https://stacksjs.dev/docs/hashing
1043
+ */
1044
+ threads?: number;
1045
+ /**
1046
+ * **Argon time**
1047
+ *
1048
+ * Execution time.
1049
+ *
1050
+ * @default number 1
1051
+ * @see https://stacksjs.dev/docs/hashing
1052
+ */
1053
+ time?: number;
1054
+ }
1055
+ type HashAlgorithm = 'md4' | 'md5' | 'sha1' | 'sha256' | 'sha384' | 'sha512' | 'ripemd128' | 'ripemd160' | 'tiger128' | 'tiger160' | 'tiger192' | 'crc32' | 'crc32b';
1056
+
1057
+ interface VitePluginVueI18nOptions {
1058
+ forceStringify?: boolean;
1059
+ runtimeOnly?: boolean;
1060
+ compositionOnly?: boolean;
1061
+ fullInstall?: boolean;
1062
+ include?: string | string[];
1063
+ defaultSFCLang?: 'json' | 'json5' | 'yml' | 'yaml';
1064
+ globalSFCScope?: boolean;
1065
+ useVueI18nImportName?: boolean;
1066
+ }
1067
+ /**
1068
+ * **Internationalization Options**
1069
+ *
1070
+ * The i18n option.
1071
+ *
1072
+ * @see https://github.com/intlify/bundle-tools/blob/main/packages/vite-plugin-vue-i18n/src/options.ts
1073
+ */
1074
+ type i18nOptions = VitePluginVueI18nOptions;
1075
+
1076
+ /**
1077
+ * **Inspect Options**
1078
+ *
1079
+ * The inspect options.
1080
+ *
1081
+ * @see https://github.com/intlify/bundle-tools/blob/main/packages/vite-plugin-vue-i18n/src/options.ts
1082
+ */
1083
+ type InspectOptions = Options;
1084
+
1085
+ /**
1086
+ * **Layout Options**
1087
+ *
1088
+ * The layout options.
1089
+ */
1090
+ type LayoutOptions = UserOptions;
1091
+
1092
+ /**
1093
+ * **Library Options**
1094
+ *
1095
+ * This configuration defines all of your library options. Because Stacks is fully-typed, you
1096
+ * may hover any of the options below and the definitions will be provided. In case you
1097
+ * have any questions, feel free to reach out via Discord or GitHub Discussions.
1098
+ */
1099
+ interface LibraryOptions {
1100
+ /**
1101
+ * The base name of your library/libraries.
1102
+ */
1103
+ name: string;
1104
+ /**
1105
+ * The name of your organization (parent).
1106
+ */
1107
+ parentName: string | null;
1108
+ /**
1109
+ * The package registry to use.
1110
+ */
1111
+ packageRegistry: 'npm';
1112
+ /**
1113
+ * The path of your repository.
1114
+ *
1115
+ * @example
1116
+ * "your-org/your-repo"
1117
+ */
1118
+ repository: string;
1119
+ /**
1120
+ * The list of accepted SPDX licenses.
1121
+ * When developing OS packages, you may want to utilize an OSI approved license.
1122
+ *
1123
+ * @example
1124
+ * "MIT"
1125
+ * @see https://opensource.org/licenses
1126
+ */
1127
+ license: LicenseType;
1128
+ /**
1129
+ * The author's name of the library.
1130
+ */
1131
+ author: string;
1132
+ /**
1133
+ * A list of all the contributors.
1134
+ */
1135
+ contributors: string[];
1136
+ /**
1137
+ * The default language used within your stack.
1138
+ */
1139
+ defaultLanguage: LanguageCode;
1140
+ /**
1141
+ * The Vue component library options.
1142
+ */
1143
+ vueComponents: LibraryBuildOptions;
1144
+ /**
1145
+ * The Web Component library options.
1146
+ */
1147
+ webComponents: LibraryBuildOptions;
1148
+ /**
1149
+ * The Web Component library options.
1150
+ */
1151
+ functions: LibraryBuildOptions;
1152
+ }
1153
+ /**
1154
+ * The list of available options to build your library.
1155
+ */
1156
+ interface LibraryBuildOptions {
1157
+ /**
1158
+ * The name of your library as published to npm.
1159
+ */
1160
+ name: string;
1161
+ /**
1162
+ * The description of your library as published to npm.
1163
+ */
1164
+ description: string;
1165
+ /**
1166
+ * The keywords of your library as published to npm.
1167
+ */
1168
+ keywords: string[];
1169
+ /**
1170
+ * Should your library generate a sourcemap?
1171
+ * @default false
1172
+ */
1173
+ shouldGenerateSourcemap?: boolean;
1174
+ /**
1175
+ * This is where you define the functions/composables that need to be included
1176
+ * in your library. For example, including your `counter` function to be
1177
+ * built would require `../functions/counter.ts` to be present.
1178
+ */
1179
+ functions?: string[];
1180
+ /**
1181
+ * This is where you define the components that need to be included in
1182
+ * your library. For example, including your `HelloWorld` to be built
1183
+ * would require `../components/HelloWorld.vue` to be present.
1184
+ *
1185
+ * @example
1186
+ * {
1187
+ * tags: [{
1188
+ * name: 'HelloWorld' // export { default as HelloWorld } from './components/HelloWorld.vue'
1189
+ * }]
1190
+ * }
1191
+ *
1192
+ * @example
1193
+ * {
1194
+ * tags: [{
1195
+ * name: ['HelloWorld', 'AppHelloWorld'] // export { default as AppHelloWorld } from './components/HelloWorld.vue'
1196
+ * }]
1197
+ * }
1198
+ */
1199
+ tags?: TagsOptions;
1200
+ }
1201
+ /**
1202
+ * The name of your "Stack" which generally is your library name
1203
+ * or a concatenation of your organization & library name.
1204
+ */
1205
+ type StackName = string;
1206
+ /**
1207
+ * The list of accepted SPDX licenses.
1208
+ * When developing OS packages, you may want to utilize an OSI approved license.
1209
+ * @see https://opensource.org/licenses
1210
+ */
1211
+ type LicenseType = 'CC-BY-NC-ND-2.0' | 'SGI-B-2.0' | 'LPPL-1.3c' | 'NIST-PD-fallback' | 'libtiff' | 'XSkat' | 'PDDL-1.0' | 'KiCad-libraries-exception' | 'CC-BY-NC-SA-1.0' | 'GFDL-1.1-no-invariants-only' | 'Xerox' | 'LPPL-1.1' | 'VOSTROM' | 'UCL-1.0' | 'ADSL' | 'OSL-2.0' | 'AAL' | 'FDK-AAC' | 'W3C-20150513' | 'AFL-1.1' | 'W3C' | 'Sleepycat' | 'CECILL-1.1' | 'mpich2' | 'SISSL' | 'NLOD-1.0' | 'ANTLR-PD' | 'GPL-3.0-only' | 'gnuplot' | 'NLOD-2.0' | 'BSD-3-Clause-Open-MPI' | 'LiLiQ-P-1.1' | 'BSD-3-Clause-Clear' | 'FSFUL' | 'CC-BY-NC-SA-2.0-UK' | 'CERN-OHL-S-2.0' | 'Spencer-94' | 'CERN-OHL-1.2' | 'GFDL-1.1-or-later' | 'AGPL-1.0-or-later' | 'Wsuipa' | 'AML' | 'BSD-2-Clause' | 'DSDP' | 'CC-BY-2.5' | 'MIT-CMU' | 'Beerware' | 'Sendmail' | 'TU-Berlin-1.0' | 'CNRI-Jython' | 'mplus' | 'CPOL-1.02' | 'BSD-3-Clause-No-Nuclear-License-2014' | 'ISC' | 'CC-BY-SA-4.0' | 'Eurosym' | 'LGPL-3.0-only' | 'OLDAP-1.3' | 'GFDL-1.1-invariants-or-later' | 'Glulxe' | 'SimPL-2.0' | 'CDLA-Permissive-2.0' | 'GPL-2.0-with-font-exception' | 'OGL-UK-2.0' | 'CC-BY-SA-3.0-DE' | 'CC-BY-ND-1.0' | 'GFDL-1.1' | 'CC-BY-4.0' | 'OpenSSL' | 'TU-Berlin-2.0' | 'DOC' | 'GFDL-1.2-no-invariants-or-later' | 'QPL-1.0' | 'OLDAP-2.8' | 'OML' | 'OLDAP-2.7' | 'NIST-PD' | 'Bitstream-Vera' | 'GFDL-1.2-or-later' | 'OFL-1.1-RFN' | 'Bahyph' | 'Barr' | 'COIL-1.0' | 'GFDL-1.3' | 'CECILL-B' | 'JPNIC' | 'Zed' | 'ICU' | 'CC-BY-NC-SA-2.5' | 'CC-BY-ND-3.0-DE' | 'bzip2-1.0.5' | 'SPL-1.0' | 'YPL-1.0' | 'OSET-PL-2.1' | 'Noweb' | 'RPSL-1.0' | 'BSD-3-Clause-LBNL' | 'CDLA-Sharing-1.0' | 'CECILL-1.0' | 'AMPAS' | 'APAFML' | 'CC-BY-ND-3.0' | 'D-FSL-1.0' | 'CC-BY-NC-3.0' | 'libpng-2.0' | 'PolyForm-Noncommercial-1.0.0' | 'dvipdfm' | 'GFDL-1.3-or-later' | 'OGTSL' | 'NPL-1.1' | 'GPL-3.0' | 'CERN-OHL-P-2.0' | 'BlueOak-1.0.0' | 'AGPL-3.0-or-later' | 'blessing' | 'ImageMagick' | 'APSL-2.0' | 'MIT-advertising' | 'curl' | 'CC0-1.0' | 'Zimbra-1.4' | 'SSPL-1.0' | 'psutils' | 'CC-BY-SA-2.0-UK' | 'PSF-2.0' | 'Net-SNMP' | 'NAIST-2003' | 'GFDL-1.2-invariants-or-later' | 'SGI-B-1.0' | 'NBPL-1.0' | 'GFDL-1.2-invariants-only' | 'W3C-19980720' | 'OFL-1.0-no-RFN' | 'NetCDF' | 'TMate' | 'NOSL' | 'CNRI-Python-GPL-Compatible' | 'BSD-1-Clause' | 'CC-BY-NC-SA-3.0-DE' | 'BSD-3-Clause-Modification' | 'GLWTPL' | 'GFDL-1.3-only' | 'OLDAP-2.2' | 'CC-BY-ND-4.0' | 'CC-BY-NC-ND-3.0-DE' | 'EUPL-1.0' | 'Linux-OpenIB' | 'LGPL-2.0-or-later' | 'OSL-1.1' | 'Spencer-86' | 'LGPL-2.0' | 'CC-PDDC' | 'CC-BY-NC-ND-3.0' | 'CDL-1.0' | 'Elastic-2.0' | 'CC-BY-2.0' | 'BSD-3-Clause-No-Military-License' | 'IJG' | 'LPPL-1.3a' | 'SAX-PD' | 'BitTorrent-1.0' | 'OLDAP-2.0' | 'Giftware' | 'C-UDA-1.0' | 'LGPL-2.0+' | 'Rdisc' | 'GPL-2.0-with-classpath-exception' | 'CC-BY-3.0-US' | 'CDDL-1.0' | 'Xnet' | 'CPL-1.0' | 'LGPL-3.0-or-later' | 'NASA-1.3' | 'BUSL-1.1' | 'etalab-2.0' | 'MIT-open-group' | 'OLDAP-1.4' | 'GFDL-1.1-invariants-only' | 'RPL-1.1' | 'CC-BY-NC-ND-2.5' | 'FSFULLR' | 'Saxpath' | 'NTP-0' | 'SISSL-1.2' | 'GPL-3.0-or-later' | 'Apache-1.1' | 'CC-BY-SA-2.1-JP' | 'AGPL-3.0-only' | 'GPL-2.0-with-autoconf-exception' | 'Artistic-2.0' | 'App-s2p' | 'Unicode-DFS-2015' | 'diffmark' | 'SNIA' | 'CC-BY-SA-2.5' | 'Linux-man-pages-copyleft' | 'HPND-sell-variant' | 'ZPL-2.1' | 'BSD-4-Clause-UC' | 'LAL-1.2' | 'AGPL-1.0-only' | 'MIT-enna' | 'Condor-1.1' | 'Naumen' | 'GFDL-1.3-no-invariants-or-later' | 'RPL-1.5' | 'PolyForm-Small-Business-1.0.0' | 'EFL-1.0' | 'MirOS' | 'CC-BY-2.5-AU' | 'Afmparse' | 'MPL-2.0-no-copyleft-exception' | 'LiLiQ-Rplus-1.1' | 'AFL-1.2' | 'OSL-1.0' | 'GPL-1.0-only' | 'APSL-1.0' | 'OGL-Canada-2.0' | 'CPAL-1.0' | 'Latex2e' | 'Zend-2.0' | 'Unlicense' | 'xpp' | 'CC-BY-NC-1.0' | 'GPL-3.0-with-autoconf-exception' | 'CC-BY-NC-SA-3.0' | 'TCP-wrappers' | 'SCEA' | 'SSH-short' | 'CC-BY-3.0-NL' | 'SchemeReport' | 'CC-BY-3.0' | 'MPL-2.0' | 'Unicode-TOU' | 'CC-BY-NC-ND-1.0' | 'Entessa' | 'BSD-3-Clause-No-Nuclear-License' | 'SWL' | 'GFDL-1.2-no-invariants-only' | 'Parity-7.0.0' | 'OLDAP-2.2.1' | 'SGI-B-1.1' | 'FTL' | 'OLDAP-2.4' | 'CC-BY-NC-4.0' | 'bzip2-1.0.6' | 'copyleft-next-0.3.0' | 'MakeIndex' | 'NRL' | 'GFDL-1.3-invariants-or-later' | 'CC-BY-NC-2.0' | 'SugarCRM-1.1.3' | 'AFL-2.1' | 'GPL-2.0-only' | 'GFDL-1.3-invariants-only' | 'TORQUE-1.1' | 'Ruby' | 'X11' | 'Borceux' | 'Libpng' | 'X11-distribute-modifications-variant' | 'Frameworx-1.0' | 'NCGL-UK-2.0' | 'CECILL-2.1' | 'CC-BY-3.0-AT' | 'CNRI-Python' | 'NCSA' | 'gSOAP-1.3b' | 'EUPL-1.1' | 'AMDPLPA' | 'Imlib2' | 'CDDL-1.1' | 'WTFPL' | 'LPL-1.0' | 'EPL-1.0' | 'BSD-3-Clause-Attribution' | 'OSL-3.0' | 'RHeCos-1.1' | 'PHP-3.0' | 'BSD-Protection' | 'CC-BY-NC-3.0-DE' | 'APL-1.0' | 'EUDatagrid' | 'GPL-1.0' | 'SHL-0.5' | 'CC-BY-SA-2.0' | 'CC-BY-SA-3.0-AT' | 'CC-BY-NC-SA-3.0-IGO' | 'Adobe-2006' | 'Newsletr' | 'Nunit' | 'Multics' | 'OGL-UK-1.0' | 'Vim' | 'eCos-2.0' | 'Zimbra-1.3' | 'eGenix' | 'IBM-pibs' | 'BitTorrent-1.1' | 'OFL-1.1-no-RFN' | 'psfrag' | 'CC-BY-ND-2.0' | 'SHL-0.51' | 'FreeBSD-DOC' | 'Python-2.0' | 'Mup' | 'BSD-4-Clause-Shortened' | 'CC-BY-NC-SA-4.0' | 'HPND' | 'OLDAP-2.6' | 'MPL-1.1' | 'GPL-2.0-with-GCC-exception' | 'HaskellReport' | 'ECL-1.0' | 'LGPL-2.1-or-later' | 'OFL-1.0' | 'APSL-1.1' | 'MITNFA' | 'CECILL-2.0' | 'Crossword' | 'Aladdin' | 'Baekmuk' | 'XFree86-1.1' | 'GPL-1.0-or-later' | 'CERN-OHL-W-2.0' | 'CC-BY-SA-1.0' | 'NTP' | 'PHP-3.01' | 'OCLC-2.0' | 'CC-BY-3.0-DE' | 'CC-BY-NC-2.5' | 'Zlib' | 'CATOSL-1.1' | 'LGPL-3.0+' | 'CAL-1.0' | 'NPL-1.0' | 'SMLNJ' | 'GPL-2.0+' | 'OLDAP-2.5' | 'JasPer-2.0' | 'GPL-2.0-or-later' | 'BSD-2-Clause-Patent' | 'MS-RL' | 'CUA-OPL-1.0' | 'IPA' | 'NLPL' | 'O-UDA-1.0' | 'MIT-Modern-Variant' | 'OLDAP-1.2' | 'BSD-2-Clause-FreeBSD' | 'Info-ZIP' | 'CC-BY-NC-SA-2.0-FR' | '0BSD' | 'Unicode-DFS-2016' | 'OFL-1.0-RFN' | 'Intel' | 'AFL-2.0' | 'GL2PS' | 'TAPR-OHL-1.0' | 'Apache-1.0' | 'MTLL' | 'Motosoto' | 'RSA-MD' | 'Community-Spec-1.0' | 'ODC-By-1.0' | 'zlib-acknowledgement' | 'DL-DE-BY-2.0' | 'VSL-1.0' | 'LiLiQ-R-1.1' | 'OPL-1.0' | 'GPL-3.0+' | 'MulanPSL-2.0' | 'APSL-1.2' | 'OGDL-Taiwan-1.0' | 'RSCPL' | 'OGC-1.0' | 'EFL-2.0' | 'CAL-1.0-Combined-Work-Exception' | 'MS-PL' | 'Plexus' | 'Sendmail-8.23' | 'Cube' | 'JSON' | 'EUPL-1.2' | 'Adobe-Glyph' | 'FreeImage' | 'Watcom-1.0' | 'Jam' | 'Hippocratic-2.1' | 'OLDAP-2.0.1' | 'CC-BY-NC-SA-2.0' | 'Nokia' | 'OCCT-PL' | 'ErlPL-1.1' | 'TOSL' | 'OSL-2.1' | 'ClArtistic' | 'xinetd' | 'GPL-3.0-with-GCC-exception' | 'ODbL-1.0' | 'MIT' | 'LGPL-2.1+' | 'LGPL-2.1-only' | 'CrystalStacker' | 'ECL-2.0' | 'LPPL-1.0' | 'iMatix' | 'CC-BY-NC-ND-3.0-IGO' | 'BSD-Source-Code' | 'Parity-6.0.0' | 'TCL' | 'Arphic-1999' | 'CC-BY-SA-3.0' | 'Caldera' | 'AGPL-1.0' | 'IPL-1.0' | 'LAL-1.3' | 'EPICS' | 'NGPL' | 'DRL-1.0' | 'BSD-2-Clause-NetBSD' | 'ZPL-1.1' | 'GD' | 'LPPL-1.2' | 'Dotseqn' | 'Spencer-99' | 'OLDAP-2.3' | 'YPL-1.1' | 'Fair' | 'Qhull' | 'GFDL-1.1-no-invariants-or-later' | 'CECILL-C' | 'MulanPSL-1.0' | 'OLDAP-1.1' | 'OLDAP-2.1' | 'LPL-1.02' | 'UPL-1.0' | 'Abstyles' | 'ZPL-2.0' | 'MIT-0' | 'LGPL-2.0-only' | 'GFDL-1.3-no-invariants-only' | 'AGPL-3.0' | 'EPL-2.0' | 'AFL-3.0' | 'CDLA-Permissive-1.0' | 'Artistic-1.0' | 'CC-BY-NC-ND-4.0' | 'HTMLTIDY' | 'Glide' | 'FSFAP' | 'LGPLLR' | 'OGL-UK-3.0' | 'GFDL-1.2' | 'SSH-OpenSSH' | 'GFDL-1.1-only' | 'MIT-feh' | 'MPL-1.0' | 'PostgreSQL' | 'OLDAP-2.2.2' | 'SMPPL' | 'OFL-1.1' | 'Leptonica' | 'CERN-OHL-1.1' | 'BSD-3-Clause-No-Nuclear-Warranty' | 'CC-BY-ND-2.5' | 'CC-BY-1.0' | 'GFDL-1.2-only' | 'OPUBL-1.0' | 'libselinux-1.0' | 'BSD-3-Clause' | 'ANTLR-PD-fallback' | 'copyleft-next-0.3.1' | 'GPL-1.0+' | 'wxWindows' | 'LGPL-3.0' | 'LGPL-2.1' | 'StandardML-NJ' | 'BSD-4-Clause' | 'GPL-2.0-with-bison-exception' | 'Apache-2.0' | 'Artistic-1.0-cl8' | 'GPL-2.0' | 'Intel-ACPI' | 'BSL-1.0' | 'Artistic-1.0-Perl' | 'BSD-2-Clause-Views' | 'Interbase-1.0' | 'NPOSL-3.0';
1212
+ /**
1213
+ * The list of accepted language codes.
1214
+ * @see https://meta.wikimedia.org/wiki/Template:List_of_language_names_ordered_by_code
1215
+ */
1216
+ type LanguageCode = 'aa' | 'ab' | 'af' | 'ak' | 'als' | 'am' | 'an' | 'ang' | 'ang' | 'ar' | 'arc' | 'as' | 'ast' | 'av' | 'awa' | 'ay' | 'az' | 'ba' | 'bar' | 'bat-smg' | 'bcl' | 'be' | 'be-x-old' | 'bg' | 'bh' | 'bi' | 'bm' | 'bn' | 'bo' | 'bpy' | 'br' | 'brx' | 'bs' | 'bug' | 'bxr' | 'ca' | 'cdo' | 'ce' | 'ceb' | 'ch' | 'cho' | 'chr' | 'chy' | 'ckb' | 'co' | 'cr' | 'cs' | 'csb' | 'cu' | 'cv' | 'cy' | 'da' | 'de' | 'diq' | 'dsb' | 'dv' | 'dz' | 'ee' | 'el' | 'en' | 'eo' | 'es' | 'et' | 'eu' | 'ext' | 'fa' | 'ff' | 'fi' | 'fiu-vro' | 'fj' | 'fo' | 'fr' | 'frp' | 'fur' | 'fy' | 'ga' | 'gan' | 'gbm' | 'gd' | 'gil' | 'gl' | 'gn' | 'got' | 'gu' | 'gv' | 'ha' | 'hak' | 'haw' | 'he' | 'hi' | 'ho' | 'hr' | 'ht' | 'hu' | 'hy' | 'hz' | 'ia' | 'id' | 'ie' | 'ig' | 'ii' | 'ik' | 'ilo' | 'inh' | 'io' | 'is' | 'it' | 'iu' | 'ja' | 'jbo' | 'jv' | 'ka' | 'kg' | 'ki' | 'kj' | 'kk' | 'kl' | 'km' | 'kn' | 'khw' | 'ko' | 'kr' | 'ks' | 'ksh' | 'ku' | 'kv' | 'kw' | 'ky' | 'la' | 'lad' | 'lan' | 'lb' | 'lg' | 'li' | 'lij' | 'lmo' | 'ln' | 'lo' | 'lzz' | 'lt' | 'lv' | 'map-bms' | 'mg' | 'man' | 'mh' | 'mi' | 'min' | 'mk' | 'ml' | 'mn' | 'mo' | 'mr' | 'mrh' | 'ms' | 'mt' | 'mus' | 'mwl' | 'my' | 'na' | 'nah' | 'nap' | 'nd' | 'nds' | 'nds-nl' | 'ne' | 'new' | 'ng' | 'nl' | 'nn' | 'no' | 'nr' | 'nso' | 'nrm' | 'nv' | 'ny' | 'oc' | 'oj' | 'om' | 'or' | 'os' | 'pa' | 'pag' | 'pam' | 'pap' | 'pdc' | 'pi' | 'pih' | 'pl' | 'pms' | 'ps' | 'pt' | 'qu' | 'rm' | 'rmy' | 'rn' | 'ro' | 'roa-rup' | 'ru' | 'rw' | 'sa' | 'sc' | 'scn' | 'sco' | 'sd' | 'se' | 'sg' | 'sh' | 'si' | 'sk' | 'sl' | 'sm' | 'sn' | 'so' | 'sq' | 'sr' | 'ss' | 'st' | 'su' | 'sv' | 'sw' | 'ta' | 'te' | 'tet' | 'tg' | 'th' | 'ti' | 'tk' | 'tl' | 'tlh' | 'tn' | 'to' | 'tpi' | 'tr' | 'ts' | 'tt' | 'tum' | 'tw' | 'ty' | 'udm' | 'ug' | 'uk' | 'ur' | 'uz' | 'uz_AF' | 've' | 'vi' | 'vec' | 'vls' | 'vo' | 'wa' | 'war' | 'wo' | 'xal' | 'xh' | 'xmf' | 'yi' | 'yo' | 'za' | 'zh' | 'zh-classical' | 'zh-min-nan' | 'zh-yue' | 'zu';
1217
+
1218
+ /**
1219
+ * The npm package manifest (package.json)
1220
+ */
1221
+ interface Manifest {
1222
+ name: string;
1223
+ version: string;
1224
+ description: string;
1225
+ [key: string]: unknown;
1226
+ }
1227
+
1228
+ type Money = Dinero<number>;
1229
+
1230
+ interface NotificationOptions {
1231
+ default: 'email' | 'sms' | 'chat' | string;
1232
+ email: {
1233
+ default: 'emailjs' | 'mailgun' | 'mailjet' | 'mandrill' | 'netcore' | 'nodemailer' | 'postmark' | 'sendgrid' | 'ses' | string;
1234
+ from: {
1235
+ name: string;
1236
+ address: string;
1237
+ };
1238
+ drivers: {
1239
+ smtp: {
1240
+ host: string;
1241
+ port: number;
1242
+ secure: boolean;
1243
+ auth: {
1244
+ user: string;
1245
+ pass: string;
1246
+ };
1247
+ };
1248
+ sendgrid: {
1249
+ key: string;
1250
+ senderName: string;
1251
+ };
1252
+ emailjs: {
1253
+ host: string;
1254
+ user: string;
1255
+ password: string;
1256
+ port: number;
1257
+ secure: boolean;
1258
+ };
1259
+ mailgun: {
1260
+ key: string;
1261
+ domain: string;
1262
+ username: string;
1263
+ };
1264
+ mailjet: {
1265
+ key: string;
1266
+ secret: string;
1267
+ };
1268
+ mandrill: {
1269
+ key: string;
1270
+ };
1271
+ netcore: {
1272
+ key: string;
1273
+ };
1274
+ nodemailer: {
1275
+ host: string;
1276
+ user: string;
1277
+ password: string;
1278
+ port: number;
1279
+ secure: boolean;
1280
+ };
1281
+ postmark: {
1282
+ key: string;
1283
+ };
1284
+ ses: {
1285
+ region: string;
1286
+ key: string;
1287
+ secret: string;
1288
+ };
1289
+ };
1290
+ };
1291
+ sms: {
1292
+ default: 'twilio' | 'nexmo' | 'gupshup' | 'plivo' | 'sms77' | 'sns' | 'telnyx' | 'termii' | string;
1293
+ from: string;
1294
+ drivers: {
1295
+ twilio: {
1296
+ sid: string;
1297
+ authToken: string;
1298
+ };
1299
+ nexmo: {
1300
+ key: string;
1301
+ secret: string;
1302
+ };
1303
+ gupshup: {
1304
+ user: string;
1305
+ password: string;
1306
+ };
1307
+ plivo: {
1308
+ sid: string;
1309
+ authToken: string;
1310
+ };
1311
+ sms77: {
1312
+ key: string;
1313
+ };
1314
+ sns: {
1315
+ region: string;
1316
+ key: string;
1317
+ secret: string;
1318
+ };
1319
+ telnyx: {
1320
+ key: string;
1321
+ messageProfileId: string;
1322
+ };
1323
+ termii: {
1324
+ key: string;
1325
+ };
1326
+ };
1327
+ };
1328
+ chat: {
1329
+ default: 'slack' | 'msTeams' | 'discord' | string;
1330
+ from: string;
1331
+ drivers: {
1332
+ slack?: {
1333
+ appId: string;
1334
+ clientId: string;
1335
+ secret: string;
1336
+ };
1337
+ msTeams?: {
1338
+ appId: string;
1339
+ clientId: string;
1340
+ secret: string;
1341
+ };
1342
+ discord?: {};
1343
+ };
1344
+ };
1345
+ }
1346
+ interface FCMPushNotificationOptions {
1347
+ eventName: string;
1348
+ to: {
1349
+ subscriberId: string;
1350
+ };
1351
+ payload: {
1352
+ deviceTokens: Array<string>;
1353
+ badge: boolean;
1354
+ clickAction: string;
1355
+ color: string;
1356
+ icon: string;
1357
+ sound: string;
1358
+ };
1359
+ }
1360
+ interface ExpoPushNotificationOptions {
1361
+ eventName: string;
1362
+ to: {
1363
+ subscriberId: string;
1364
+ };
1365
+ payload: {
1366
+ to: string[];
1367
+ data: Object;
1368
+ title: string;
1369
+ body: string;
1370
+ ttl: number;
1371
+ expiration: number;
1372
+ priority: 'default' | 'normal' | 'high';
1373
+ subtitle: string;
1374
+ sound: 'default' | null;
1375
+ badge: number;
1376
+ channelId: string;
1377
+ categoryId: string;
1378
+ mutableContent: boolean;
1379
+ };
1380
+ }
1381
+
1382
+ type EmailOptions = Omit<IEmailOptions, 'from'> & {
1383
+ from: {
1384
+ name?: string;
1385
+ address?: string;
1386
+ };
1387
+ domain?: string;
1388
+ mailboxes?: {
1389
+ [key: string]: string;
1390
+ };
1391
+ };
1392
+
1393
+ interface PagesOption {
1394
+ onboarding: {
1395
+ path: string;
1396
+ pages: string[];
1397
+ };
1398
+ settings: {
1399
+ path: string;
1400
+ pages: string[];
1401
+ };
1402
+ }
1403
+
1404
+ interface PaymentOptions {
1405
+ driver: 'stripe';
1406
+ }
1407
+ interface ChargeOptions {
1408
+ currency?: string;
1409
+ source?: string;
1410
+ description?: string;
1411
+ chargeId?: string;
1412
+ limit?: number;
1413
+ metadata?: object;
1414
+ searchOptions: {
1415
+ query?: string;
1416
+ limit?: number;
1417
+ };
1418
+ }
1419
+ interface CustomerOptions {
1420
+ description?: string;
1421
+ address?: string;
1422
+ email?: string;
1423
+ metadata?: object;
1424
+ name?: string;
1425
+ payment_method?: string;
1426
+ shipping: string;
1427
+ listOptions?: {
1428
+ created?: object;
1429
+ ending_before?: string;
1430
+ limit?: number;
1431
+ starting_after?: string;
1432
+ test_clock?: string;
1433
+ };
1434
+ searchOptions?: {
1435
+ query?: string;
1436
+ limit?: number;
1437
+ page?: number;
1438
+ };
1439
+ }
1440
+ interface DisputeOptions {
1441
+ dp_id?: string;
1442
+ metadata?: object;
1443
+ listOptions?: {
1444
+ charge?: string;
1445
+ payment_intent?: string;
1446
+ created?: string;
1447
+ ending_before?: string;
1448
+ limit?: number;
1449
+ starting_after?: string;
1450
+ };
1451
+ }
1452
+ interface EventOptions {
1453
+ event_id?: string;
1454
+ listOptions?: {
1455
+ created?: object;
1456
+ delivery_success?: boolean;
1457
+ ending_before?: string;
1458
+ limit?: number;
1459
+ starting_after?: string;
1460
+ type?: string;
1461
+ };
1462
+ }
1463
+
1464
+ type MaybePromise<T> = T | Promise<T>;
1465
+
1466
+ /**
1467
+ * **PWA Options**
1468
+ *
1469
+ * The PWA options.
1470
+ */
1471
+ type PwaOptions = Options$1;
1472
+
1473
+ interface QueueOptions {
1474
+ default: 'sync' | 'database' | 'redis' | 'sqs';
1475
+ connections: {
1476
+ sync: {
1477
+ driver: 'sync';
1478
+ };
1479
+ database: {
1480
+ driver: 'database';
1481
+ table: 'jobs';
1482
+ queue: 'default';
1483
+ retry_after: 90;
1484
+ };
1485
+ redis: {
1486
+ driver: 'redis';
1487
+ connection: 'default';
1488
+ queue: 'default';
1489
+ retry_after: 90;
1490
+ };
1491
+ sqs: {
1492
+ driver: 'sqs';
1493
+ key: '';
1494
+ secret: '';
1495
+ prefix: '';
1496
+ suffix: '';
1497
+ queue: 'default';
1498
+ region: 'us-east-1';
1499
+ };
1500
+ };
1501
+ failed: {
1502
+ driver: 'database';
1503
+ database: 'mysql';
1504
+ table: 'failed_jobs';
1505
+ };
1506
+ }
1507
+
1508
+ interface NitroEventHandler {
1509
+ /**
1510
+ * Path prefix or route
1511
+ *
1512
+ * If an empty string used, will be used as a middleware
1513
+ */
1514
+ route?: string;
1515
+ /**
1516
+ * Specifies this is a middleware handler.
1517
+ * Middleware are called on every route and should normally return nothing to pass to the next handlers
1518
+ */
1519
+ middleware?: boolean;
1520
+ /**
1521
+ * Use lazy loading to import handler
1522
+ */
1523
+ lazy?: boolean;
1524
+ /**
1525
+ * Path to event handler
1526
+ *
1527
+ */
1528
+ handler: string;
1529
+ /**
1530
+ * Router method matcher
1531
+ */
1532
+ method?: string;
1533
+ }
1534
+ type HttpMethod = 'get' | 'post' | 'put' | 'patch' | 'delete' | 'before' | 'after' | 'view';
1535
+ type RouteCallback = (params: Record<string, any>) => any;
1536
+ interface Route {
1537
+ method: HttpMethod;
1538
+ pattern: RegExp;
1539
+ callback: RouteCallback;
1540
+ paramNames: string[];
1541
+ }
1542
+ interface Middleware {
1543
+ before?: RouteCallback;
1544
+ after?: RouteCallback;
1545
+ }
1546
+ interface RouteGroupOptions {
1547
+ prefix?: string;
1548
+ middleware?: Middleware[];
1549
+ }
1550
+
1551
+ type Search = any;
1552
+ type Page = any;
1553
+ type Pages = Page[];
1554
+ type Filter = any;
1555
+ type Filters = Filter[];
1556
+ type Result = any;
1557
+ type Results = Result[];
1558
+ type SearchFilter = any;
1559
+ type SearchFilters = SearchFilter[];
1560
+ type Sorts = any;
1561
+ type Sort = any;
1562
+ interface SearchEngineOptions {
1563
+ /**
1564
+ * **Search Engine Driver**
1565
+ *
1566
+ * The search engine to utilize.
1567
+ *
1568
+ * @default string 'meilisearch'
1569
+ * @see https://stacksjs.dev/docs/search-engine
1570
+ */
1571
+ driver: 'meilisearch' | 'algolia';
1572
+ meilisearch?: {
1573
+ host: string;
1574
+ apiKey: string;
1575
+ };
1576
+ }
1577
+ interface ServicesOptions {
1578
+ algolia?: {
1579
+ appId: string;
1580
+ apiKey: string;
1581
+ };
1582
+ meilisearch?: {
1583
+ appId: string;
1584
+ apiKey: string;
1585
+ };
1586
+ stripe?: {
1587
+ appId: string;
1588
+ apiKey: string;
1589
+ };
1590
+ planetscale?: {
1591
+ appId: string;
1592
+ apiKey: string;
1593
+ };
1594
+ supabase?: {
1595
+ appId: string;
1596
+ apiKey: string;
1597
+ };
1598
+ aws?: {
1599
+ appId: string;
1600
+ apiKey: string;
1601
+ };
1602
+ novu?: {
1603
+ key: string;
1604
+ };
1605
+ }
1606
+ interface StorageOptions {
1607
+ /**
1608
+ * **Storage Driver**
1609
+ *
1610
+ * The storage driver to utilize.
1611
+ *
1612
+ * @default string 's3'
1613
+ * @see https://stacksjs.dev/docs/storage
1614
+ */
1615
+ driver: 's3' | 'local';
1616
+ }
1617
+ interface MeiliSearchOptions {
1618
+ apiKey: string;
1619
+ host: string;
1620
+ }
1621
+ interface SearchEngineDriver {
1622
+ client: MeiliSearch;
1623
+ createIndex: (name: string, options?: IndexOptions) => MaybePromise<EnqueuedTask>;
1624
+ getIndex: (name: string) => MaybePromise<Index>;
1625
+ updateIndex?: (name: string, options: IndexOptions) => MaybePromise<EnqueuedTask>;
1626
+ deleteIndex?: (name: string) => MaybePromise<EnqueuedTask>;
1627
+ updateIndexSettings: (name: string, settings: Settings) => MaybePromise<EnqueuedTask>;
1628
+ listAllIndexes: () => MaybePromise<IndexesResults<Index[]>>;
1629
+ listAllIndices: () => MaybePromise<IndexesResults<Index[]>>;
1630
+ getRecord?: (key: string) => MaybePromise<any>;
1631
+ getRecords?: (key: string) => MaybePromise<DocumentOptions>;
1632
+ createRecord?: (record: any, indexName: string, options: DocumentOptions) => MaybePromise<EnqueuedTask>;
1633
+ createRecords?: (records: any, indexName: string, options: DocumentOptions) => MaybePromise<EnqueuedTask>;
1634
+ createOrReplaceRecord?: (record: any, indexName: string, options: DocumentOptions) => MaybePromise<EnqueuedTask>;
1635
+ createOrUpdateRecord?: (record: any, indexName: string, options: DocumentOptions) => MaybePromise<EnqueuedTask>;
1636
+ deleteRecord?: (recordId: string | number, indexName: string) => MaybePromise<EnqueuedTask>;
1637
+ deleteAllRecords?: (indexName: string) => MaybePromise<EnqueuedTask>;
1638
+ batchDeleteRecords?: (recordIds: string[] | number[], indexName: string) => MaybePromise<EnqueuedTask>;
1639
+ search?: (query: string, indexName: string, options: SearchParams) => MaybePromise<Search>;
1640
+ calculatePagination: Pages;
1641
+ currentPage: Page;
1642
+ filterName: string;
1643
+ filters: Filters;
1644
+ goToNextPage: () => Page;
1645
+ goToPage: (pageNumber: number) => Page;
1646
+ goToPrevPage: () => Page;
1647
+ hits: Hits;
1648
+ index: Index;
1649
+ lastPage: Page;
1650
+ perPage: number;
1651
+ query: string;
1652
+ results: Results;
1653
+ searchFilters: SearchFilters;
1654
+ searchParams: SearchParams;
1655
+ setTotalHits: number;
1656
+ sort: Sort;
1657
+ sorts: Sorts;
1658
+ totalPages: number;
1659
+ }
1660
+ type SearchEngineDriverFactory<T> = (opts?: T) => SearchEngineDriver;
1661
+ /**
1662
+ * This interface is used to unify the persisting of data to localStorage
1663
+ */
1664
+ interface SearchEngineStorage {
1665
+ /**
1666
+ * The search engine index name.
1667
+ * i.e. the type of table, like `users`, `posts`, `products`, etc.
1668
+ */
1669
+ index?: string;
1670
+ /**
1671
+ * The search engine results object.
1672
+ */
1673
+ results?: SearchResponse;
1674
+ /**
1675
+ * The search engine hits object.
1676
+ */
1677
+ hits?: Hits;
1678
+ /**
1679
+ * The number of hits to be returned per page.
1680
+ *
1681
+ * @default number 20
1682
+ */
1683
+ perPage: number;
1684
+ /**
1685
+ * The current page number.
1686
+ *
1687
+ * @default number 1
1688
+ */
1689
+ currentPage: number;
1690
+ }
1691
+
1692
+ type UserModule = (ctx: ViteSSGContext) => void;
1693
+
1694
+ /**
1695
+ * **Stacks Options**
1696
+ *
1697
+ * This configuration defines all of your Stacks options. Because Stacks is fully-typed,
1698
+ * you may hover any of the options below and the definitions will be provided. In case
1699
+ * you have any questions, feel free to reach out via Discord or GitHub Discussions.
1700
+ */
1701
+ interface StacksOptions {
1702
+ /**
1703
+ * **Application Options**
1704
+ *
1705
+ * This configuration defines all of your Application options. Because Stacks is fully-typed,
1706
+ * you may hover any of the options below and the definitions will be provided. In case
1707
+ * you have any questions, feel free to reach out via Discord or GitHub Discussions.
1708
+ */
1709
+ app: Partial<AppOptions>;
1710
+ /**
1711
+ * **Cache Options**
1712
+ *
1713
+ * This configuration defines all of your Cache options. Because Stacks is fully-typed, you
1714
+ * may hover any of the options below and the definitions will be provided. In case you
1715
+ * have any questions, feel free to reach out via Discord or GitHub Discussions.
1716
+ */
1717
+ cache: Partial<CacheOptions>;
1718
+ /**
1719
+ * **CDN Options**
1720
+ *
1721
+ * This configuration defines all of your CDN options. Because Stacks is fully-typed, you
1722
+ * may hover any of the options below and the definitions will be provided. In case you
1723
+ * have any questions, feel free to reach out via Discord or GitHub Discussions.
1724
+ */
1725
+ cdn: Partial<CdnOptions>;
1726
+ /**
1727
+ * **CLI Options**
1728
+ *
1729
+ * This configuration defines all of your CLI options. Because Stacks is fully-typed, you
1730
+ * may hover any of the options below and the definitions will be provided. In case you
1731
+ * have any questions, feel free to reach out via Discord or GitHub Discussions.
1732
+ */
1733
+ cli: Partial<UserCliOptions>;
1734
+ /**
1735
+ * **Database Options**
1736
+ *
1737
+ * This configuration defines all of your Database options. Because Stacks is fully-typed, you
1738
+ * may hover any of the options below and the definitions will be provided. In case you
1739
+ * have any questions, feel free to reach out via Discord or GitHub Discussions.
1740
+ */
1741
+ database: Partial<DatabaseOptions>;
1742
+ /**
1743
+ * **Debug Options**
1744
+ *
1745
+ * This configuration defines all of your Debug options. Because Stacks is fully-typed, you
1746
+ * may hover any of the options below and the definitions will be provided. In case you
1747
+ * have any questions, feel free to reach out via Discord or GitHub Discussions.
1748
+ */
1749
+ debug: Partial<DebugOptions>;
1750
+ /**
1751
+ * **DNS Options**
1752
+ *
1753
+ * This configuration defines all of your DNS options. Because Stacks is fully-typed, you
1754
+ * may hover any of the options below and the definitions will be provided. In case you
1755
+ * have any questions, feel free to reach out via Discord or GitHub Discussions.
1756
+ */
1757
+ dns: Partial<DnsOptions>;
1758
+ /**
1759
+ * **Docs Options**
1760
+ *
1761
+ * This configuration defines all of your Docs options. Because Stacks is fully-typed, you
1762
+ * may hover any of the options below and the definitions will be provided. In case you
1763
+ * have any questions, feel free to reach out via Discord or GitHub Discussions.
1764
+ */
1765
+ docs: Partial<DocsOptions>;
1766
+ /**
1767
+ * **Email Options**
1768
+ *
1769
+ * This configuration defines all of your Email options. Because Stacks is fully-typed, you
1770
+ * may hover any of the options below and the definitions will be provided. In case you
1771
+ * have any questions, feel free to reach out via Discord or GitHub Discussions.
1772
+ */
1773
+ email: Partial<EmailOptions>;
1774
+ /**
1775
+ * **Git Options**
1776
+ *
1777
+ * This configuration defines all of your Git options. Because Stacks is fully-typed, you
1778
+ * may hover any of the options below and the definitions will be provided. In case you
1779
+ * have any questions, feel free to reach out via Discord or GitHub Discussions.
1780
+ */
1781
+ git: Partial<GitOptions>;
1782
+ /**
1783
+ * **Hashing Options**
1784
+ *
1785
+ * This configuration defines all of your Hashing options. Because Stacks is fully-typed, you
1786
+ * may hover any of the options below and the definitions will be provided. In case you
1787
+ * have any questions, feel free to reach out via Discord or GitHub Discussions.
1788
+ */
1789
+ hashing: Partial<HashingOptions>;
1790
+ /**
1791
+ * **Library Options**
1792
+ *
1793
+ * This configuration defines all of your Library options. Because Stacks is fully-typed, you
1794
+ * may hover any of the options below and the definitions will be provided. In case you
1795
+ * have any questions, feel free to reach out via Discord or GitHub Discussions.
1796
+ */
1797
+ library: Partial<LibraryOptions>;
1798
+ /**
1799
+ * **Notification Options**
1800
+ *
1801
+ * This configuration defines all of your Notification options. Because Stacks is fully-typed,
1802
+ * you may hover any of the options below and the definitions will be provided. In case
1803
+ * you have any questions, feel free to reach out via Discord or GitHub Discussions.
1804
+ */
1805
+ notification: Partial<NotificationOptions>;
1806
+ /**
1807
+ * **Payment Options**
1808
+ *
1809
+ * This configuration defines all of your Payment options. Because Stacks is fully-typed,
1810
+ * you may hover any of the options below and the definitions will be provided. In case
1811
+ * you have any questions, feel free to reach out via Discord or GitHub Discussions.
1812
+ */
1813
+ payment: Partial<PaymentOptions>;
1814
+ /**
1815
+ * **Search Engine Options**
1816
+ *
1817
+ * This configuration defines all of your Search Engine options. Because Stacks is fully-typed,
1818
+ * you may hover any of the options below and the definitions will be provided. In case
1819
+ * you have any questions, feel free to reach out via Discord or GitHub Discussions.
1820
+ */
1821
+ searchEngine: Partial<SearchEngineOptions>;
1822
+ /**
1823
+ * **Services Options**
1824
+ *
1825
+ * This configuration defines all of your Services options. Because Stacks is fully-typed,
1826
+ * you may hover any of the options below and the definitions will be provided. In case
1827
+ * you have any questions, feel free to reach out via Discord or GitHub Discussions.
1828
+ */
1829
+ services: Partial<ServicesOptions>;
1830
+ /**
1831
+ * **Storage Options**
1832
+ *
1833
+ * This configuration defines all of your Storage options. Because Stacks is fully-typed,
1834
+ * you may hover any of the options below and the definitions will be provided. In case
1835
+ * you have any questions, feel free to reach out via Discord or GitHub Discussions.
1836
+ */
1837
+ /**
1838
+ * **UI Options**
1839
+ *
1840
+ * This configuration defines all of your UI options. Because Stacks is fully-typed, you
1841
+ * may hover any of the options below and the definitions will be provided. In case you
1842
+ * have any questions, feel free to reach out via Discord or GitHub Discussions.
1843
+ */
1844
+ ui: Partial<UiOptions>;
1845
+ }
1846
+ type ResolvedStacksOptions = Required<StacksOptions>;
1847
+
1848
+ /**
1849
+ * the TableStore interface is primarily used to unify the persisting of data to localStorage
1850
+ */
1851
+ interface TableStore {
1852
+ /**
1853
+ * The search engine index name.
1854
+ * i.e. the type of table, like `users`, `posts`, `products`, etc.
1855
+ */
1856
+ index: string;
1857
+ /**
1858
+ * The search engine results object.
1859
+ */
1860
+ results?: SearchResponse<Record<string, any>>;
1861
+ /**
1862
+ * The search engine hits object.
1863
+ */
1864
+ hits?: Hits;
1865
+ columns: string[];
1866
+ source?: string;
1867
+ password?: string;
1868
+ searchable?: string | boolean;
1869
+ query?: string;
1870
+ sortable?: string | boolean;
1871
+ sort?: string;
1872
+ sorts?: string | string[];
1873
+ filterable?: string | boolean;
1874
+ filters?: string | string[];
1875
+ filterValue?: any[];
1876
+ actionable?: string | boolean;
1877
+ actions?: string | string[];
1878
+ perPage: number;
1879
+ selectable?: string | boolean;
1880
+ selectedRows?: number[] | string[];
1881
+ selectedAll?: boolean;
1882
+ goToNextPage: number;
1883
+ goToPage: number;
1884
+ goToPrevPage: number;
1885
+ lastPageNumber: number;
1886
+ searchFilters?: object;
1887
+ searchParams?: object;
1888
+ setTotalHits: number;
1889
+ /**
1890
+ *
1891
+ * The current page number
1892
+ * @default 1
1893
+ * @type {number}
1894
+ * @memberof TableStore
1895
+ * @example 1
1896
+ */
1897
+ currentPage: number;
1898
+ }
1899
+
1900
+ type Font = 'inter' | 'mona' | 'hubot';
1901
+ type Icon = 'heroicon-outline' | 'heroicon-solid';
1902
+ type WebFontsProviders = 'google' | 'bunny' | 'fontshare';
1903
+ interface FontInfo {
1904
+ title: string;
1905
+ text: string;
1906
+ }
1907
+ type FontFor = 'email' | 'desktop' | 'mobile' | 'web';
1908
+ interface WebFontMeta {
1909
+ name: string;
1910
+ weights?: (string | number)[];
1911
+ italic?: boolean;
1912
+ provider?: WebFontsProviders;
1913
+ }
1914
+ /**
1915
+ * **UI Engine Options**
1916
+ *
1917
+ * This type defines all of your UI Engine options. Because Stacks is fully-typed, you may
1918
+ * hover any of the options below and the definitions will be provided. In case you
1919
+ * have any questions, feel free to reach out via Discord or GitHub Discussions.
1920
+ */
1921
+ interface UiOptions {
1922
+ /**
1923
+ * **Shortcuts**
1924
+ *
1925
+ * Shortcuts provide you with the ability to combine
1926
+ * utility names for reusability purposes.
1927
+ *
1928
+ * @example
1929
+ * ```
1930
+ * shortcuts: {
1931
+ * 'btn': 'px-4 py-2 rounded text-white bg-blue-500',
1932
+ * 'btn-lg': 'btn px-6 py-3',
1933
+ * }
1934
+ * ```
1935
+ */
1936
+ shortcuts: Shortcuts;
1937
+ /**
1938
+ * **Safelist**
1939
+ *
1940
+ * Use the `safelist` option to ensure the generation of
1941
+ * those utility classes. This is useful when certain
1942
+ * class names don’t exist in your content files.
1943
+ *
1944
+ * @example
1945
+ * ```ts
1946
+ * safelist: [
1947
+ * 'btn',
1948
+ * 'btn-lg',
1949
+ * 'btn-blue',
1950
+ * 'btn-blue-500',
1951
+ * ]
1952
+ */
1953
+ safelist: string;
1954
+ /**
1955
+ * **Trigger String**
1956
+ *
1957
+ * The "trigger string" defines the class name markup
1958
+ * you want to add into your components.
1959
+ *
1960
+ * @default ':stx:'
1961
+ *
1962
+ * @example
1963
+ * ```ts
1964
+ * trigger: ':stx:'
1965
+ * ```
1966
+ */
1967
+ trigger?: string;
1968
+ /**
1969
+ * **Class Prefix**
1970
+ *
1971
+ * The prefix for the compiled class name. When transforming
1972
+ * all utility classes into a single class, this prefix
1973
+ * will be added to the generated CSS class name.
1974
+ *
1975
+ * @default 'stx-'
1976
+ *
1977
+ * @example
1978
+ * ```ts
1979
+ * prefix: 'stx-'
1980
+ * ```
1981
+ */
1982
+ classPrefix?: string;
1983
+ /**
1984
+ * **Hash Function**
1985
+ *
1986
+ * The hash function used to generate the class name.
1987
+ *
1988
+ * @example
1989
+ * ```ts
1990
+ * hash: (str: string) => {
1991
+ * return str
1992
+ * .split('')
1993
+ * .reduce((a, b) => {
1994
+ * a = ((a << 5) - a) + b.charCodeAt(0)
1995
+ * return a & a
1996
+ * }, 0)
1997
+ * .toString(36)
1998
+ * }
1999
+ */
2000
+ hashFn?: (str: string) => string;
2001
+ /**
2002
+ * **CSS Resets—Preset**
2003
+ *
2004
+ * Define a standard of reset CSS stylesheets. By default, the Tailwind
2005
+ * reset styles are utilized. You may set this value to `null`
2006
+ * if you prefer not applying any default stylesheets.
2007
+ *
2008
+ * @url https://www.npmjs.com/package/@unocss/reset
2009
+ * @todo preset needs to be added via a Vite plugin on development & build
2010
+ * @example
2011
+ * ```ts
2012
+ * reset: 'tailwind'
2013
+ * ```
2014
+ */
2015
+ reset?: ResetPreset;
2016
+ /**
2017
+ * **Fonts**
2018
+ *
2019
+ * Define the fonts you want to use. By default, Stacks provides support
2020
+ * for several local font providers. You may set this value to
2021
+ * `null` if you prefer not utilize any local fonts.
2022
+ *
2023
+ * @see https://stacks.ow3.org/fonts
2024
+ * @example applies the same font for all platforms _(web, email, desktop, and mobile)_
2025
+ * ```ts
2026
+ * fonts: {
2027
+ * title: 'Mona',
2028
+ * text: 'Hubot'
2029
+ * }
2030
+ * ```
2031
+ * @example
2032
+ * ```ts
2033
+ * fonts: {
2034
+ * web: {
2035
+ * title: 'Inter',
2036
+ * text: 'Mona'
2037
+ * },
2038
+ * desktop: {
2039
+ * title: 'Mona',
2040
+ * text: 'Inter'
2041
+ * },
2042
+ * }
2043
+ * ```
2044
+ */
2045
+ fonts?: Record<FontFor, FontInfo> | {
2046
+ [key in FontFor]: FontInfo;
2047
+ };
2048
+ useWebFonts?: boolean | WebFontsProviders;
2049
+ /**
2050
+ * **Icon Sets**
2051
+ *
2052
+ * This value defines the icon sets you want to use. When using icons, they
2053
+ * are displayed utilizing a technique called "icons in pure css."
2054
+ * Learn more here https://antfu.me/posts/icons-in-pure-css.
2055
+ *
2056
+ * @see https://stacks.ow3.org/config/icons — list of available icon sets
2057
+ * @todo implement this into Vite build flow
2058
+ * @example
2059
+ * ```ts
2060
+ * icons: ['heroicons']
2061
+ * ```
2062
+ * @example
2063
+ * ```html
2064
+ * <i class="i-heroicons-outline-book-open w-8 h-8 text-gray-500" aria-hidden="true" />
2065
+ * ```
2066
+ */
2067
+ icons: Icon | Icon[];
2068
+ }
2069
+ type Shortcuts = UserShortcuts;
2070
+ /**
2071
+ * **Style Reset — Preset**
2072
+ *
2073
+ * This value sets the "reset preset." A preset defines certain
2074
+ * CSS defaults to be applied.
2075
+ *
2076
+ * @default "tailwind"
2077
+ */
2078
+ type ResetPreset = 'tailwind' | 'normalize' | 'sanitize' | 'eric-meyer' | 'antfu' | null;
2079
+
2080
+ /**
2081
+ * Null or whatever.
2082
+ */
2083
+ type Nullable<T> = T | null | undefined;
2084
+ /**
2085
+ * Function
2086
+ */
2087
+ type Fn<T = void> = () => T;
2088
+ /**
2089
+ * Array, or not yet
2090
+ */
2091
+ type Arrayable<T> = T | Array<T>;
2092
+ /**
2093
+ * Constructor.
2094
+ */
2095
+ type Constructor<T = void> = new (...args: any[]) => T;
2096
+ /**
2097
+ * Defines an intersection type of all union items.
2098
+ *
2099
+ * @param U Union of any types that will be intersected.
2100
+ * @returns U items intersected
2101
+ * @see https://stackoverflow.com/a/50375286/9259330
2102
+ */
2103
+ type UnionToIntersection<U> = (U extends unknown ? (k: U) => void : never) extends ((k: infer I) => void) ? I : never;
2104
+ type MergeInsertions<T> = T extends object ? {
2105
+ [K in keyof T]: MergeInsertions<T[K]>;
2106
+ } : T;
2107
+ type DeepMerge<F, S> = MergeInsertions<{
2108
+ [K in keyof F | keyof S]: K extends keyof S & keyof F ? DeepMerge<F[K], S[K]> : K extends keyof S ? S[K] : K extends keyof F ? F[K] : never;
2109
+ }>;
2110
+
2111
+ export { AAAARecord, ARecord, Action, ActionOption, ActionOptions, AddOption, AddOptions, AppOptions, ArgonOptions, Arrayable, AuthOptions, BcryptOptions, BuildOption, BuildOptions, CNameRecord, CacheOptions, CdnOptions, ChargeOptions, CleanOptions, CliOptions, CliOptionsKeys, CommandResult, CommandReturnValue, CommitOptions, Constructor, CreateBooleanOption, CreateOptions, CreateStringOption, CronJob, CronJobOptions, CronJobs, CustomerOptions, DatabaseClient, DatabaseDriver, DatabaseOptions, DebugOptions, DeepMerge, DeployOptions, DevOption, DevOptions, DisputeOptions, DnsOptions, DnsRecord, DocsConfig, DocsOptions, EmailOptions, EventOptions, Events, Every, ExamplesBoolean, ExamplesOption, ExamplesOptions, ExamplesString, ExitCode, ExpoPushNotificationOptions, FCMPushNotificationOptions, FactoryOptions, Fields, Fn, Font, FontFor, FontInfo, FreshOptions, GeneratorOption, GeneratorOptions, GitHooks, GitOptions, HashAlgorithm, HashingOptions, HttpMethod, Icon, InspectOptions, InspireOptions, IntroOptions, Job, JobOptions, Jobs, JsonFile, KeyOptions, LanguageCode, LayoutOptions, LibEntryType, LibraryBuildOptions, LibraryOptions, LicenseType, LintOption, LintOptions, MXRecord, MakeBooleanOption, MakeOptions, MakeStringOption, Manifest, MaybePromise, MeiliSearchOptions, MergeInsertions, Middleware, Model, Money, NitroEventHandler, NotificationOptions, NpmScript, Nullable, OutroOptions, PackageJson, PagesOption, PaymentOptions, PreinstallOptions, PrepublishOptions, PwaOptions, QueueOptions, ReleaseOptions, ResetPreset, ResolvedStacksOptions, Route, RouteCallback, RouteGroupOptions, SchemaOptions, SearchEngineDriver, SearchEngineDriverFactory, SearchEngineOptions, SearchEngineStorage, SeedOptions, ServicesOptions, Shortcuts, StackName, StacksError, StacksOptions, StorageOptions, TableStore, TagOption, TagsOptions, TestOptions, TextFile, TimestampOptions, TinkerOptions, TxtRecord, TypesOptions, UiOptions, UnionToIntersection, UpgradeBoolean, UpgradeOptions, UpgradeString, UserCliOptions, UserModule, ValidationError, WebFontMeta, WebFontsProviders, i18nOptions };