@stacksjs/types 0.37.8 → 0.38.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.
- package/README.md +1 -1
- package/dist/app.d.ts +2 -2
- package/dist/build.d.ts +2 -2
- package/dist/build.mjs +1 -0
- package/dist/cli.d.ts +128 -1
- package/dist/cli.mjs +8 -0
- package/dist/errors.d.ts +1 -0
- package/dist/errors.mjs +6 -0
- package/dist/index.d.ts +1 -0
- package/dist/index.mjs +1 -0
- package/dist/ssg.d.ts +1 -1
- package/dist/ui.d.ts +2 -1
- package/package.json +25 -14
package/README.md
CHANGED
|
@@ -36,7 +36,7 @@ pnpm test
|
|
|
36
36
|
|
|
37
37
|
## 📈 Changelog
|
|
38
38
|
|
|
39
|
-
Please see our [releases](https://github.com/stacksjs/
|
|
39
|
+
Please see our [releases](https://github.com/stacksjs/stacks/releases) page for more information on what has changed recently.
|
|
40
40
|
|
|
41
41
|
## 💪🏼 Contributing
|
|
42
42
|
|
package/dist/app.d.ts
CHANGED
|
@@ -25,7 +25,7 @@ export interface AppOptions {
|
|
|
25
25
|
*
|
|
26
26
|
* @default "local"
|
|
27
27
|
*/
|
|
28
|
-
env?: '
|
|
28
|
+
env?: 'local' | 'development' | 'production';
|
|
29
29
|
/**
|
|
30
30
|
* ### Application URL
|
|
31
31
|
*
|
|
@@ -45,7 +45,7 @@ export interface AppOptions {
|
|
|
45
45
|
* stack traces will be shown on every error that occurs within your
|
|
46
46
|
* application. If disabled, a simple generic error page is shown.
|
|
47
47
|
*
|
|
48
|
-
* @default
|
|
48
|
+
* @default true
|
|
49
49
|
*/
|
|
50
50
|
debug: boolean;
|
|
51
51
|
/**
|
package/dist/build.d.ts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
|
|
2
|
-
export
|
|
1
|
+
export type { UserConfig as ViteConfig } from 'vite';
|
|
2
|
+
export { type ViteSSGContext } from 'vite-ssg';
|
package/dist/build.mjs
CHANGED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {} from "vite-ssg";
|
package/dist/cli.d.ts
CHANGED
|
@@ -1,11 +1,128 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* The parsed command-line arguments
|
|
3
3
|
*/
|
|
4
|
+
import type { Ora } from 'ora';
|
|
4
5
|
export interface StacksOptions {
|
|
5
6
|
componentsSrcPath?: string;
|
|
6
7
|
dtsPath?: string;
|
|
7
8
|
extensions?: string[];
|
|
8
9
|
}
|
|
10
|
+
export interface OutroOptions {
|
|
11
|
+
startTime?: number;
|
|
12
|
+
useSeconds?: boolean;
|
|
13
|
+
isError?: boolean;
|
|
14
|
+
}
|
|
15
|
+
export interface IntroOptions {
|
|
16
|
+
/**
|
|
17
|
+
* @default true
|
|
18
|
+
*/
|
|
19
|
+
showPerformance?: boolean;
|
|
20
|
+
}
|
|
21
|
+
declare type SpinnerOptions = Ora;
|
|
22
|
+
/**
|
|
23
|
+
* The options to pass to the CLI.
|
|
24
|
+
*/
|
|
25
|
+
export interface CliOptions {
|
|
26
|
+
/**
|
|
27
|
+
* ### CLI Debug Level
|
|
28
|
+
*
|
|
29
|
+
* When your application is in debug mode, a different level of information,
|
|
30
|
+
* like stack traces, will be shown on every error that occurs within the
|
|
31
|
+
* application. When disabled, it defaults to the "normal experience."
|
|
32
|
+
*
|
|
33
|
+
* @default false
|
|
34
|
+
*/
|
|
35
|
+
debug?: boolean;
|
|
36
|
+
/**
|
|
37
|
+
* ### Current Work Directory
|
|
38
|
+
*
|
|
39
|
+
* Based on the `cwd` value, that's where the command...
|
|
40
|
+
*
|
|
41
|
+
* @default projectPath()
|
|
42
|
+
*/
|
|
43
|
+
cwd?: string;
|
|
44
|
+
/**
|
|
45
|
+
* ### Loading Animation
|
|
46
|
+
*
|
|
47
|
+
* Should the command show a loading animation?
|
|
48
|
+
* Please note, when debug mode is enabled,
|
|
49
|
+
* the animation will not show.
|
|
50
|
+
*
|
|
51
|
+
* @default true
|
|
52
|
+
*/
|
|
53
|
+
shouldBeAnimated?: boolean | SpinnerOptions;
|
|
54
|
+
}
|
|
55
|
+
export type { Ora as SpinnerOptions } from 'ora';
|
|
56
|
+
export declare type ActionsOption = 'types';
|
|
57
|
+
export declare type ActionsOptions = {
|
|
58
|
+
[key in ActionsOption]?: boolean;
|
|
59
|
+
} & CliOptions;
|
|
60
|
+
export declare type BuildOption = 'components' | 'vueComponents' | 'webComponents' | 'elements' | 'functions' | 'docs' | 'pages' | 'stacks' | 'all';
|
|
61
|
+
export declare type BuildOptions = {
|
|
62
|
+
[key in BuildOption]: boolean;
|
|
63
|
+
} & CliOptions;
|
|
64
|
+
export declare type AddOption = 'table' | 'calendar' | 'all';
|
|
65
|
+
export declare type AddOptions = {
|
|
66
|
+
[key in AddOption]?: boolean;
|
|
67
|
+
} & CliOptions;
|
|
68
|
+
export declare type CreateStringOption = 'name';
|
|
69
|
+
export declare type CreateBooleanOption = 'ui' | 'components' | 'web-components' | 'vue' | 'pages' | 'functions' | 'api' | 'database';
|
|
70
|
+
export declare type CreateOptions = {
|
|
71
|
+
[key in CreateBooleanOption]: boolean;
|
|
72
|
+
} & {
|
|
73
|
+
[key in CreateStringOption]: string;
|
|
74
|
+
} & CliOptions;
|
|
75
|
+
export declare type DevOption = 'components' | 'docs' | 'pages' | 'functions' | 'all';
|
|
76
|
+
export declare type DevOptions = {
|
|
77
|
+
[key in DevOption]: boolean;
|
|
78
|
+
} & CliOptions;
|
|
79
|
+
export declare type GeneratorOption = 'types' | 'entries' | 'webTypes' | 'customData' | 'ideHelpers' | 'vueCompatibility' | 'componentMeta';
|
|
80
|
+
export declare type GeneratorOptions = {
|
|
81
|
+
[key in GeneratorOption]?: boolean;
|
|
82
|
+
} & CliOptions;
|
|
83
|
+
export declare type LintOption = 'fix';
|
|
84
|
+
export declare type LintOptions = {
|
|
85
|
+
[key in LintOption]: boolean;
|
|
86
|
+
} & CliOptions;
|
|
87
|
+
export declare type MakeStringOption = 'name';
|
|
88
|
+
export declare type MakeBooleanOption = 'component' | 'page' | 'function' | 'language' | 'database' | 'migration' | 'factory' | 'notification' | 'stack';
|
|
89
|
+
export declare type MakeOptions = {
|
|
90
|
+
[key in MakeBooleanOption]: boolean;
|
|
91
|
+
} & {
|
|
92
|
+
[key in MakeStringOption]: string;
|
|
93
|
+
} & CliOptions;
|
|
94
|
+
export declare type UpdateString = 'version';
|
|
95
|
+
export declare type UpdateBoolean = 'framework' | 'dependencies' | 'packageManager' | 'node' | 'all' | 'force';
|
|
96
|
+
export declare type UpdateOptions = {
|
|
97
|
+
[key in UpdateString]: string;
|
|
98
|
+
} & {
|
|
99
|
+
[key in UpdateBoolean]: boolean;
|
|
100
|
+
} & CliOptions;
|
|
101
|
+
export declare type ExamplesString = 'version';
|
|
102
|
+
export declare type ExamplesBoolean = 'components' | 'vue' | 'webComponents' | 'elements' | 'all' | 'force';
|
|
103
|
+
export declare type ExamplesOption = ExamplesString & ExamplesBoolean | void;
|
|
104
|
+
export declare type ExamplesOptions = {
|
|
105
|
+
[key in ExamplesString]: string;
|
|
106
|
+
} & {
|
|
107
|
+
[key in ExamplesBoolean]: boolean;
|
|
108
|
+
} & CliOptions;
|
|
109
|
+
export interface TestOptions extends CliOptions {
|
|
110
|
+
}
|
|
111
|
+
export interface CleanOptions extends CliOptions {
|
|
112
|
+
}
|
|
113
|
+
export interface CommitOptions extends CliOptions {
|
|
114
|
+
}
|
|
115
|
+
export interface KeyOptions extends CliOptions {
|
|
116
|
+
}
|
|
117
|
+
export interface FreshOptions extends CliOptions {
|
|
118
|
+
}
|
|
119
|
+
export interface ReleaseOptions extends CliOptions {
|
|
120
|
+
}
|
|
121
|
+
export interface PreinstallOptions extends CliOptions {
|
|
122
|
+
}
|
|
123
|
+
export interface PrepublishOptions extends CliOptions {
|
|
124
|
+
}
|
|
125
|
+
export declare type LibEntryType = 'vue-components' | 'web-components' | 'functions' | 'all';
|
|
9
126
|
/**
|
|
10
127
|
* The available npm scripts within the Stacks toolkit.
|
|
11
128
|
*/
|
|
@@ -16,14 +133,18 @@ export declare const enum NpmScript {
|
|
|
16
133
|
BuildFunctions = "build:functions",
|
|
17
134
|
BuildDocs = "build:docs",
|
|
18
135
|
BuildStacks = "build:stacks",
|
|
136
|
+
Clean = "clean",
|
|
19
137
|
Dev = "dev",
|
|
20
138
|
DevComponents = "dev:components",
|
|
21
139
|
DevDocs = "dev:docs",
|
|
140
|
+
DevPages = "dev:pages",
|
|
141
|
+
DevFunctions = "dev:functions",
|
|
22
142
|
Fresh = "fresh",
|
|
23
143
|
Update = "update",
|
|
24
144
|
UpdateDependencies = "update:dependencies",
|
|
25
145
|
UpdateFramework = "update:framework",
|
|
26
146
|
UpdatePackageManager = "update:package-manager",
|
|
147
|
+
UpdateNode = "update:node",
|
|
27
148
|
Lint = "lint",
|
|
28
149
|
LintFix = "lint:fix",
|
|
29
150
|
MakeStack = "make:stack",
|
|
@@ -31,6 +152,7 @@ export declare const enum NpmScript {
|
|
|
31
152
|
TestTypes = "test:types",
|
|
32
153
|
TestCoverage = "test:coverage",
|
|
33
154
|
Generate = "generate",
|
|
155
|
+
GenerateTypes = "generate:types",
|
|
34
156
|
GenerateEntries = "generate:entries",
|
|
35
157
|
GenerateVueCompat = "generate:vue-compatibility",
|
|
36
158
|
GenerateWebTypes = "generate:web-types",
|
|
@@ -44,5 +166,10 @@ export declare const enum NpmScript {
|
|
|
44
166
|
ExampleWebComponents = "example:web-components",
|
|
45
167
|
KeyGenerate = "key:generate",
|
|
46
168
|
TypesFix = "types:fix",
|
|
47
|
-
TypesGenerate = "types:generate"
|
|
169
|
+
TypesGenerate = "types:generate",
|
|
170
|
+
Preinstall = "preinstall",
|
|
171
|
+
Prepublish = "prepublish",
|
|
172
|
+
Wip = "wip"
|
|
48
173
|
}
|
|
174
|
+
export type { CAC as CLI } from 'cac';
|
|
175
|
+
export type { ExecaReturnValue as CommandResult } from 'execa';
|
package/dist/cli.mjs
CHANGED
|
@@ -5,14 +5,18 @@ export var NpmScript = /* @__PURE__ */ ((NpmScript2) => {
|
|
|
5
5
|
NpmScript2["BuildFunctions"] = "build:functions";
|
|
6
6
|
NpmScript2["BuildDocs"] = "build:docs";
|
|
7
7
|
NpmScript2["BuildStacks"] = "build:stacks";
|
|
8
|
+
NpmScript2["Clean"] = "clean";
|
|
8
9
|
NpmScript2["Dev"] = "dev";
|
|
9
10
|
NpmScript2["DevComponents"] = "dev:components";
|
|
10
11
|
NpmScript2["DevDocs"] = "dev:docs";
|
|
12
|
+
NpmScript2["DevPages"] = "dev:pages";
|
|
13
|
+
NpmScript2["DevFunctions"] = "dev:functions";
|
|
11
14
|
NpmScript2["Fresh"] = "fresh";
|
|
12
15
|
NpmScript2["Update"] = "update";
|
|
13
16
|
NpmScript2["UpdateDependencies"] = "update:dependencies";
|
|
14
17
|
NpmScript2["UpdateFramework"] = "update:framework";
|
|
15
18
|
NpmScript2["UpdatePackageManager"] = "update:package-manager";
|
|
19
|
+
NpmScript2["UpdateNode"] = "update:node";
|
|
16
20
|
NpmScript2["Lint"] = "lint";
|
|
17
21
|
NpmScript2["LintFix"] = "lint:fix";
|
|
18
22
|
NpmScript2["MakeStack"] = "make:stack";
|
|
@@ -20,6 +24,7 @@ export var NpmScript = /* @__PURE__ */ ((NpmScript2) => {
|
|
|
20
24
|
NpmScript2["TestTypes"] = "test:types";
|
|
21
25
|
NpmScript2["TestCoverage"] = "test:coverage";
|
|
22
26
|
NpmScript2["Generate"] = "generate";
|
|
27
|
+
NpmScript2["GenerateTypes"] = "generate:types";
|
|
23
28
|
NpmScript2["GenerateEntries"] = "generate:entries";
|
|
24
29
|
NpmScript2["GenerateVueCompat"] = "generate:vue-compatibility";
|
|
25
30
|
NpmScript2["GenerateWebTypes"] = "generate:web-types";
|
|
@@ -34,5 +39,8 @@ export var NpmScript = /* @__PURE__ */ ((NpmScript2) => {
|
|
|
34
39
|
NpmScript2["KeyGenerate"] = "key:generate";
|
|
35
40
|
NpmScript2["TypesFix"] = "types:fix";
|
|
36
41
|
NpmScript2["TypesGenerate"] = "types:generate";
|
|
42
|
+
NpmScript2["Preinstall"] = "preinstall";
|
|
43
|
+
NpmScript2["Prepublish"] = "prepublish";
|
|
44
|
+
NpmScript2["Wip"] = "wip";
|
|
37
45
|
return NpmScript2;
|
|
38
46
|
})(NpmScript || {});
|
package/dist/errors.d.ts
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { Err, Ok, Result, ResultAsync, } from 'neverthrow';
|
package/dist/errors.mjs
ADDED
package/dist/index.d.ts
CHANGED
package/dist/index.mjs
CHANGED
package/dist/ssg.d.ts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { type ViteSSGContext } from '
|
|
1
|
+
import { type ViteSSGContext } from '@stacksjs/types';
|
|
2
2
|
export declare type UserModule = (ctx: ViteSSGContext) => void;
|
package/dist/ui.d.ts
CHANGED
|
@@ -14,11 +14,12 @@ export interface UiOptions {
|
|
|
14
14
|
* utility names for reusability purposes.
|
|
15
15
|
*
|
|
16
16
|
* @example
|
|
17
|
-
* ```
|
|
17
|
+
* ```
|
|
18
18
|
* shortcuts: {
|
|
19
19
|
* 'btn': 'px-4 py-2 rounded text-white bg-blue-500',
|
|
20
20
|
* 'btn-lg': 'btn px-6 py-3',
|
|
21
21
|
* }
|
|
22
|
+
* ```
|
|
22
23
|
*/
|
|
23
24
|
shortcuts: Shortcuts;
|
|
24
25
|
/**
|
package/package.json
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@stacksjs/types",
|
|
3
3
|
"type": "module",
|
|
4
|
-
"version": "0.
|
|
5
|
-
"packageManager": "pnpm@7.
|
|
4
|
+
"version": "0.38.3",
|
|
5
|
+
"packageManager": "pnpm@7.15.0",
|
|
6
6
|
"description": "The Stacks framework types.",
|
|
7
7
|
"author": "Chris Breuer",
|
|
8
8
|
"license": "MIT",
|
|
@@ -29,27 +29,38 @@
|
|
|
29
29
|
"Chris Breuer <chris@ow3.org>"
|
|
30
30
|
],
|
|
31
31
|
"files": [
|
|
32
|
-
"dist"
|
|
32
|
+
"dist",
|
|
33
|
+
"README.md"
|
|
33
34
|
],
|
|
34
35
|
"engines": {
|
|
35
|
-
"node": ">=v18.
|
|
36
|
-
"pnpm": ">=7.
|
|
36
|
+
"node": ">=v18.12.1",
|
|
37
|
+
"pnpm": ">=7.15.0"
|
|
37
38
|
},
|
|
38
|
-
"
|
|
39
|
+
"devDependencies": {
|
|
39
40
|
"@mdit-vue/plugin-component": "^0.11.1",
|
|
40
41
|
"@mdit-vue/plugin-frontmatter": "^0.11.1",
|
|
41
42
|
"@mdit-vue/types": "^0.11.0",
|
|
42
43
|
"@rollup/pluginutils": "^5.0.2",
|
|
44
|
+
"@types/bcryptjs": "^2.4.2",
|
|
45
|
+
"@types/crypto-js": "^4.1.1",
|
|
46
|
+
"@types/eslint": "^8.4.10",
|
|
47
|
+
"@types/fs-extra": "^9.0.13",
|
|
48
|
+
"@types/markdown-it-link-attributes": "^3.0.1",
|
|
49
|
+
"@types/minimatch": "^5.1.2",
|
|
50
|
+
"@types/node": "^18.11.9",
|
|
51
|
+
"@types/nprogress": "^0.2.0",
|
|
52
|
+
"@types/pluralize": "^0.0.29",
|
|
53
|
+
"@types/prompts": "^2.4.1",
|
|
54
|
+
"cac": "^6.7.14",
|
|
43
55
|
"markdown-it": "^13.0.1",
|
|
44
|
-
"
|
|
45
|
-
"
|
|
46
|
-
"
|
|
47
|
-
"
|
|
56
|
+
"mkdist": "^0.4.0",
|
|
57
|
+
"typescript": "^4.8.4",
|
|
58
|
+
"unplugin-auto-import": "^0.11.4",
|
|
59
|
+
"unplugin-vue-components": "^0.22.9",
|
|
60
|
+
"vite-plugin-inspect": "^0.7.7",
|
|
48
61
|
"vite-plugin-vue-layouts": "^0.7.0",
|
|
49
|
-
"
|
|
50
|
-
|
|
51
|
-
"devDependencies": {
|
|
52
|
-
"mkdist": "^0.3.13"
|
|
62
|
+
"vite-ssg": "^0.21.2",
|
|
63
|
+
"vitepress": "1.0.0-alpha.28"
|
|
53
64
|
},
|
|
54
65
|
"scripts": {
|
|
55
66
|
"build": "mkdist -d",
|