@stacksjs/build 0.37.8 → 0.38.1
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/example-vue.mjs +4 -6
- package/dist/example-wc.mjs +4 -6
- package/dist/functions.mjs +3 -3
- package/dist/pages.mjs +4 -4
- package/dist/stacks.d.ts +4 -6
- package/dist/stacks.mjs +7 -9
- package/dist/vue-components.mjs +8 -10
- package/dist/web-components.mjs +8 -10
- package/package.json +23 -20
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/example-vue.mjs
CHANGED
|
@@ -1,16 +1,14 @@
|
|
|
1
1
|
import { defineConfig } from "vite";
|
|
2
|
-
import { examplesPath } from "@stacksjs/
|
|
3
|
-
import {
|
|
2
|
+
import { examplesPath } from "@stacksjs/path";
|
|
3
|
+
import { server } from "@stacksjs/server";
|
|
4
|
+
import { alias } from "../../runtime/alias";
|
|
4
5
|
import { uiEngine } from "./index.mjs";
|
|
5
6
|
export const vueComponentsExampleConfig = {
|
|
6
7
|
root: examplesPath("vue-components"),
|
|
7
8
|
resolve: {
|
|
8
9
|
alias
|
|
9
10
|
},
|
|
10
|
-
server
|
|
11
|
-
port: 3333,
|
|
12
|
-
open: true
|
|
13
|
-
},
|
|
11
|
+
server,
|
|
14
12
|
plugins: [
|
|
15
13
|
uiEngine()
|
|
16
14
|
]
|
package/dist/example-wc.mjs
CHANGED
|
@@ -1,16 +1,14 @@
|
|
|
1
1
|
import { defineConfig } from "vite";
|
|
2
|
-
import { examplesPath } from "@stacksjs/
|
|
3
|
-
import {
|
|
2
|
+
import { examplesPath } from "@stacksjs/path";
|
|
3
|
+
import { server } from "@stacksjs/server";
|
|
4
|
+
import { alias } from "../../runtime/alias";
|
|
4
5
|
import { uiEngine } from "./index.mjs";
|
|
5
6
|
export const webComponentsExampleConfig = {
|
|
6
7
|
root: examplesPath("web-components"),
|
|
7
8
|
resolve: {
|
|
8
9
|
alias
|
|
9
10
|
},
|
|
10
|
-
server
|
|
11
|
-
port: 3333,
|
|
12
|
-
open: true
|
|
13
|
-
},
|
|
11
|
+
server,
|
|
14
12
|
plugins: [
|
|
15
13
|
uiEngine(true)
|
|
16
14
|
]
|
package/dist/functions.mjs
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { defineConfig } from "vite";
|
|
2
|
-
import { buildEntriesPath, frameworkPath, functionsPath, projectPath } from "@stacksjs/
|
|
3
|
-
import { library } from "
|
|
4
|
-
import { alias } from "
|
|
2
|
+
import { buildEntriesPath, frameworkPath, functionsPath, projectPath } from "@stacksjs/path";
|
|
3
|
+
import { library } from "@stacksjs/config";
|
|
4
|
+
import { alias } from "../../runtime/alias";
|
|
5
5
|
import { autoImports } from "./index.mjs";
|
|
6
6
|
export const functionsConfig = {
|
|
7
7
|
root: functionsPath(),
|
package/dist/pages.mjs
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { defineConfig } from "vite";
|
|
2
2
|
import generateSitemap from "vite-ssg-sitemap";
|
|
3
|
-
import { functionsPath, projectPath } from "@stacksjs/
|
|
4
|
-
import { alias } from "
|
|
5
|
-
import {
|
|
3
|
+
import { functionsPath, projectPath } from "@stacksjs/path";
|
|
4
|
+
import { alias } from "../../runtime/alias";
|
|
5
|
+
import { autoImports, components, cssEngine, i18n, inspect, layouts, markdown, pages, preview, pwa, uiEngine } from "./index.mjs";
|
|
6
6
|
export const pagesConfig = {
|
|
7
7
|
root: functionsPath(),
|
|
8
8
|
envDir: projectPath(),
|
|
@@ -14,7 +14,7 @@ export const pagesConfig = {
|
|
|
14
14
|
preview(),
|
|
15
15
|
uiEngine(),
|
|
16
16
|
pages(),
|
|
17
|
-
|
|
17
|
+
cssEngine(),
|
|
18
18
|
components(),
|
|
19
19
|
layouts(),
|
|
20
20
|
i18n(),
|
package/dist/stacks.d.ts
CHANGED
|
@@ -1,18 +1,16 @@
|
|
|
1
1
|
import type { PluginOption } from 'vite';
|
|
2
2
|
import type { AutoImportsOptions, ComponentOptions, InspectOptions, LayoutOptions, MarkdownOptions, PagesOptions, i18nOptions } from '@stacksjs/types';
|
|
3
|
-
import { resolve } from '@stacksjs/
|
|
3
|
+
import { resolve } from '@stacksjs/path';
|
|
4
4
|
declare function inspect(options?: InspectOptions): import("vite").Plugin;
|
|
5
5
|
declare function preview(): any;
|
|
6
6
|
declare function layouts(options?: LayoutOptions): import("vite").Plugin;
|
|
7
|
-
declare function components(options?: ComponentOptions):
|
|
8
|
-
api: import("unplugin-vue-components/types").PublicPluginAPI;
|
|
9
|
-
};
|
|
7
|
+
declare function components(options?: ComponentOptions): PluginOption;
|
|
10
8
|
declare function pages(options?: PagesOptions): import("vite").Plugin;
|
|
11
9
|
declare function markdown(options?: MarkdownOptions): import("vite").Plugin;
|
|
12
10
|
declare function autoImports(options?: AutoImportsOptions): any;
|
|
13
|
-
declare function
|
|
11
|
+
declare function cssEngine(isWebComponent?: boolean): import("vite").Plugin[];
|
|
14
12
|
declare function pwa(): import("vite").Plugin[];
|
|
15
13
|
declare function i18n(options?: i18nOptions): import("vite").Plugin;
|
|
16
14
|
declare function uiEngine(isWebComponent?: boolean): import("vite").Plugin;
|
|
17
15
|
declare const componentPreset: (isWebComponent?: boolean) => PluginOption;
|
|
18
|
-
export { resolve, componentPreset, uiEngine, autoImports,
|
|
16
|
+
export { resolve, componentPreset, uiEngine, autoImports, cssEngine, components, inspect, markdown, pages, pwa, preview, layouts, i18n };
|
package/dist/stacks.mjs
CHANGED
|
@@ -12,7 +12,7 @@ import LinkAttributes from "markdown-it-link-attributes";
|
|
|
12
12
|
import Shiki from "markdown-it-shiki";
|
|
13
13
|
import { VitePWA } from "vite-plugin-pwa";
|
|
14
14
|
import { defu } from "defu";
|
|
15
|
-
import { arraysPath, collectionsPath, componentsPath, frameworkPath, fsPath, functionsPath,
|
|
15
|
+
import { arraysPath, collectionsPath, componentsPath, frameworkPath, fsPath, functionsPath, langPath, pagesPath, pathPath, projectPath, resolve, securityPath, stringsPath, uiPath } from "@stacksjs/path";
|
|
16
16
|
function inspect(options) {
|
|
17
17
|
return Inspect(options);
|
|
18
18
|
}
|
|
@@ -27,8 +27,7 @@ function components(options) {
|
|
|
27
27
|
extensions: ["vue", "md"],
|
|
28
28
|
include: [/\.vue$/, /\.vue\?vue/, /\.md$/],
|
|
29
29
|
dirs: [
|
|
30
|
-
componentsPath()
|
|
31
|
-
pagesPath()
|
|
30
|
+
componentsPath()
|
|
32
31
|
],
|
|
33
32
|
dts: frameworkPath("components.d.ts")
|
|
34
33
|
};
|
|
@@ -85,8 +84,7 @@ function autoImports(options) {
|
|
|
85
84
|
stringsPath("src"),
|
|
86
85
|
collectionsPath("src"),
|
|
87
86
|
fsPath("src"),
|
|
88
|
-
|
|
89
|
-
pathsPath("src"),
|
|
87
|
+
pathPath("src"),
|
|
90
88
|
securityPath("src")
|
|
91
89
|
],
|
|
92
90
|
dts: frameworkPath("auto-imports.d.ts"),
|
|
@@ -98,9 +96,9 @@ function autoImports(options) {
|
|
|
98
96
|
const newOptions = defu(options, defaultOptions);
|
|
99
97
|
return AutoImport(newOptions);
|
|
100
98
|
}
|
|
101
|
-
function
|
|
99
|
+
function cssEngine(isWebComponent = false) {
|
|
102
100
|
return Unocss({
|
|
103
|
-
configFile:
|
|
101
|
+
configFile: uiPath("src/unocss.ts"),
|
|
104
102
|
mode: isWebComponent ? "shadow-dom" : "vue-scoped"
|
|
105
103
|
});
|
|
106
104
|
}
|
|
@@ -160,9 +158,9 @@ function uiEngine(isWebComponent = false) {
|
|
|
160
158
|
const componentPreset = (isWebComponent = false) => [
|
|
161
159
|
inspect,
|
|
162
160
|
uiEngine(isWebComponent),
|
|
163
|
-
|
|
161
|
+
cssEngine(isWebComponent),
|
|
164
162
|
autoImports,
|
|
165
163
|
components,
|
|
166
164
|
markdown
|
|
167
165
|
];
|
|
168
|
-
export { resolve, componentPreset, uiEngine, autoImports,
|
|
166
|
+
export { resolve, componentPreset, uiEngine, autoImports, cssEngine, components, inspect, markdown, pages, pwa, preview, layouts, i18n };
|
package/dist/vue-components.mjs
CHANGED
|
@@ -1,16 +1,14 @@
|
|
|
1
1
|
import { defineConfig } from "vite";
|
|
2
|
-
import { buildEntriesPath, componentsPath, frameworkPath, projectPath } from "@stacksjs/
|
|
3
|
-
import { library } from "
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
2
|
+
import { buildEntriesPath, componentsPath, frameworkPath, projectPath } from "@stacksjs/path";
|
|
3
|
+
import { library } from "@stacksjs/config";
|
|
4
|
+
import { server } from "@stacksjs/server";
|
|
5
|
+
import { alias } from "../../runtime/alias";
|
|
6
|
+
import { autoImports, components, cssEngine, inspect, preview, uiEngine } from "./index.mjs";
|
|
6
7
|
export const vueComponentsConfig = {
|
|
7
8
|
root: componentsPath(),
|
|
8
9
|
envDir: projectPath(),
|
|
9
10
|
envPrefix: "APP_",
|
|
10
|
-
server
|
|
11
|
-
port: 3333,
|
|
12
|
-
open: true
|
|
13
|
-
},
|
|
11
|
+
server,
|
|
14
12
|
resolve: {
|
|
15
13
|
dedupe: ["vue"],
|
|
16
14
|
alias
|
|
@@ -21,7 +19,7 @@ export const vueComponentsConfig = {
|
|
|
21
19
|
plugins: [
|
|
22
20
|
preview(),
|
|
23
21
|
uiEngine(),
|
|
24
|
-
|
|
22
|
+
cssEngine(),
|
|
25
23
|
autoImports(),
|
|
26
24
|
components(),
|
|
27
25
|
inspect()
|
|
@@ -30,7 +28,7 @@ export const vueComponentsConfig = {
|
|
|
30
28
|
};
|
|
31
29
|
export function vueComponentsBuildOptions() {
|
|
32
30
|
return {
|
|
33
|
-
outDir: frameworkPath("
|
|
31
|
+
outDir: frameworkPath("components/vue/dist"),
|
|
34
32
|
emptyOutDir: true,
|
|
35
33
|
lib: {
|
|
36
34
|
entry: buildEntriesPath("vue-components.ts"),
|
package/dist/web-components.mjs
CHANGED
|
@@ -1,24 +1,22 @@
|
|
|
1
1
|
import { defineConfig } from "vite";
|
|
2
|
-
import { buildEntriesPath, componentsPath, frameworkPath, projectPath } from "@stacksjs/
|
|
3
|
-
import { library } from "
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
2
|
+
import { buildEntriesPath, componentsPath, frameworkPath, projectPath } from "@stacksjs/path";
|
|
3
|
+
import { library } from "@stacksjs/config";
|
|
4
|
+
import { server } from "@stacksjs/server";
|
|
5
|
+
import { alias } from "../../runtime/alias";
|
|
6
|
+
import { autoImports, components, cssEngine, inspect, uiEngine } from "./index.mjs";
|
|
6
7
|
const isWebComponent = true;
|
|
7
8
|
export const webComponentsConfig = {
|
|
8
9
|
root: componentsPath(),
|
|
9
10
|
envDir: projectPath(),
|
|
10
11
|
envPrefix: "APP_",
|
|
11
|
-
server
|
|
12
|
-
port: 3333,
|
|
13
|
-
open: true
|
|
14
|
-
},
|
|
12
|
+
server,
|
|
15
13
|
resolve: {
|
|
16
14
|
alias
|
|
17
15
|
},
|
|
18
16
|
plugins: [
|
|
19
17
|
inspect(),
|
|
20
18
|
uiEngine(isWebComponent),
|
|
21
|
-
|
|
19
|
+
cssEngine(isWebComponent),
|
|
22
20
|
autoImports(),
|
|
23
21
|
components()
|
|
24
22
|
],
|
|
@@ -26,7 +24,7 @@ export const webComponentsConfig = {
|
|
|
26
24
|
};
|
|
27
25
|
export function webComponentsBuildOptions() {
|
|
28
26
|
return {
|
|
29
|
-
outDir: frameworkPath("
|
|
27
|
+
outDir: frameworkPath("components/web/dist"),
|
|
30
28
|
emptyOutDir: true,
|
|
31
29
|
lib: {
|
|
32
30
|
entry: buildEntriesPath("web-components.ts"),
|
package/package.json
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@stacksjs/build",
|
|
3
3
|
"type": "module",
|
|
4
|
-
"version": "0.
|
|
5
|
-
"packageManager": "pnpm@7.
|
|
4
|
+
"version": "0.38.1",
|
|
5
|
+
"packageManager": "pnpm@7.15.0",
|
|
6
6
|
"description": "The Stacks framework build tools and configurations.",
|
|
7
7
|
"author": "Chris Breuer",
|
|
8
8
|
"license": "MIT",
|
|
@@ -30,37 +30,40 @@
|
|
|
30
30
|
"Chris Breuer <chris@ow3.org>"
|
|
31
31
|
],
|
|
32
32
|
"files": [
|
|
33
|
-
"dist"
|
|
33
|
+
"dist",
|
|
34
|
+
"README.md"
|
|
34
35
|
],
|
|
35
36
|
"engines": {
|
|
36
|
-
"node": ">=v18.
|
|
37
|
-
"pnpm": ">=7.
|
|
37
|
+
"node": ">=v18.12.1",
|
|
38
|
+
"pnpm": ">=7.15.0"
|
|
38
39
|
},
|
|
39
|
-
"
|
|
40
|
+
"peerDependencies": {
|
|
40
41
|
"@intlify/vite-plugin-vue-i18n": "^6.0.3",
|
|
41
|
-
"@stacksjs/
|
|
42
|
-
"@stacksjs/
|
|
43
|
-
"@types
|
|
44
|
-
"
|
|
45
|
-
"
|
|
42
|
+
"@stacksjs/config": "0.38.1",
|
|
43
|
+
"@stacksjs/server": "0.38.1",
|
|
44
|
+
"@stacksjs/types": "0.38.1",
|
|
45
|
+
"@stacksjs/utils": "0.38.1",
|
|
46
|
+
"@vitejs/plugin-vue": "^3.2.0",
|
|
46
47
|
"markdown-it-link-attributes": "^4.0.1",
|
|
47
|
-
"markdown-it-shiki": "^0.
|
|
48
|
-
"
|
|
49
|
-
"unplugin-
|
|
50
|
-
"
|
|
51
|
-
"vite
|
|
52
|
-
"vite-plugin-
|
|
53
|
-
"vite-plugin-
|
|
48
|
+
"markdown-it-shiki": "^0.6.1",
|
|
49
|
+
"unbuild": "^0.9.4",
|
|
50
|
+
"unplugin-auto-import": "^0.11.4",
|
|
51
|
+
"unplugin-vue-components": "^0.22.9",
|
|
52
|
+
"vite": "^3.2.3",
|
|
53
|
+
"vite-plugin-inspect": "^0.7.7",
|
|
54
|
+
"vite-plugin-pages": "^0.27.1",
|
|
55
|
+
"vite-plugin-pwa": "^0.13.3",
|
|
54
56
|
"vite-plugin-vue-component-preview": "^0.3.3",
|
|
55
57
|
"vite-plugin-vue-layouts": "^0.7.0",
|
|
56
58
|
"vite-plugin-vue-markdown": "^0.22.1",
|
|
57
|
-
"vite-ssg": "^0.21.
|
|
59
|
+
"vite-ssg": "^0.21.2",
|
|
58
60
|
"vite-ssg-sitemap": "^0.4.3",
|
|
59
61
|
"vue-docgen-web-types": "^0.1.8",
|
|
60
62
|
"vue-i18n": "^9.2.2"
|
|
61
63
|
},
|
|
62
64
|
"devDependencies": {
|
|
63
|
-
"mkdist": "^0.
|
|
65
|
+
"mkdist": "^0.4.0",
|
|
66
|
+
"typescript": "^4.8.4"
|
|
64
67
|
},
|
|
65
68
|
"scripts": {
|
|
66
69
|
"build": "mkdist -d",
|