@stacksjs/docs 0.59.11 → 0.61.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.js +16 -14
- package/package.json +4 -6
- package/src/index.ts +6 -8
- package/src/meta.ts +1 -2
- package/src/plugins.ts +1 -1
- package/src/scripts/pwa.ts +9 -7
- package/dist/index.d.ts +0 -26
- package/dist/meta.d.ts +0 -15
- package/dist/plugins.d.ts +0 -3
- package/dist/scripts/pwa.d.ts +0 -2
package/dist/index.js
CHANGED
|
@@ -1,17 +1,17 @@
|
|
|
1
1
|
// src/index.ts
|
|
2
|
-
import {defineConfig} from "vitepress";
|
|
3
2
|
import {alias as alias2} from "@stacksjs/alias";
|
|
4
|
-
import {
|
|
3
|
+
import {kolorist as c} from "@stacksjs/cli";
|
|
5
4
|
import {docs as docs2} from "@stacksjs/config";
|
|
5
|
+
import {path as p} from "@stacksjs/path";
|
|
6
6
|
import {server as server2} from "@stacksjs/server";
|
|
7
|
-
import {kolorist as c} from "@stacksjs/cli";
|
|
8
7
|
import {withPwa} from "@vite-pwa/vitepress";
|
|
9
|
-
|
|
10
|
-
|
|
8
|
+
import {defineConfig} from "vitepress";
|
|
9
|
+
// package.json
|
|
10
|
+
var version = "0.61.0";
|
|
11
11
|
|
|
12
12
|
// src/scripts/pwa.ts
|
|
13
|
-
import {frameworkPath} from "@stacksjs/path";
|
|
14
13
|
import {docs} from "@stacksjs/config";
|
|
14
|
+
import {frameworkPath} from "@stacksjs/path";
|
|
15
15
|
|
|
16
16
|
// src/meta.ts
|
|
17
17
|
var googleapis = "https://fonts.googleapis.com";
|
|
@@ -28,7 +28,7 @@ var preconnectLinks = [googleapis, gstatic];
|
|
|
28
28
|
var preconnectHomeLinks = [googleapis, gstatic];
|
|
29
29
|
var pwaFontsRegex = new RegExp(`^${googleapis}/.*`, "i");
|
|
30
30
|
var pwaFontStylesRegex = new RegExp(`^${gstatic}/.*`, "i");
|
|
31
|
-
var githubusercontentRegex =
|
|
31
|
+
var githubusercontentRegex = /^https:\/\/((i.ibb.co)|((raw|user-images).githubusercontent.com))\/.*/i;
|
|
32
32
|
|
|
33
33
|
// src/scripts/pwa.ts
|
|
34
34
|
var pwaDocs = {
|
|
@@ -71,12 +71,14 @@ var pwaDocs = {
|
|
|
71
71
|
purpose: "maskable"
|
|
72
72
|
}
|
|
73
73
|
],
|
|
74
|
-
screenshots: [
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
74
|
+
screenshots: [
|
|
75
|
+
{
|
|
76
|
+
src: "og.png",
|
|
77
|
+
sizes: "2258x1185",
|
|
78
|
+
type: "image/png",
|
|
79
|
+
label: `Screenshot of ${docs.title}`
|
|
80
|
+
}
|
|
81
|
+
],
|
|
80
82
|
handle_links: "preferred",
|
|
81
83
|
launch_handler: {
|
|
82
84
|
client_mode: ["navigate-existing", "auto"]
|
|
@@ -141,8 +143,8 @@ var pwaDocs = {
|
|
|
141
143
|
};
|
|
142
144
|
|
|
143
145
|
// src/plugins.ts
|
|
144
|
-
import TwoSlashFloatingVue from "vitepress-plugin-twoslash/client";
|
|
145
146
|
import {transformerTwoslash} from "vitepress-plugin-twoslash";
|
|
147
|
+
import TwoSlashFloatingVue from "vitepress-plugin-twoslash/client";
|
|
146
148
|
|
|
147
149
|
// src/index.ts
|
|
148
150
|
var frameworkDefaults = {
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@stacksjs/docs",
|
|
3
3
|
"type": "module",
|
|
4
|
-
"version": "0.
|
|
4
|
+
"version": "0.61.0",
|
|
5
5
|
"description": "The Stacks way to document.",
|
|
6
6
|
"author": "Chris Breuer",
|
|
7
7
|
"license": "MIT",
|
|
@@ -51,8 +51,7 @@
|
|
|
51
51
|
"@stacksjs/config": "latest",
|
|
52
52
|
"@stacksjs/path": "latest",
|
|
53
53
|
"@stacksjs/server": "latest",
|
|
54
|
-
"
|
|
55
|
-
"vitepress": "1.0.0-rc.45",
|
|
54
|
+
"vitepress": "1.2.2",
|
|
56
55
|
"vitepress-plugin-twoslash": "^0.10.2"
|
|
57
56
|
},
|
|
58
57
|
"dependencies": {
|
|
@@ -60,12 +59,11 @@
|
|
|
60
59
|
"@stacksjs/config": "latest",
|
|
61
60
|
"@stacksjs/path": "latest",
|
|
62
61
|
"@stacksjs/server": "latest",
|
|
63
|
-
"
|
|
64
|
-
"vitepress": "1.0.0-rc.45",
|
|
62
|
+
"vitepress": "1.2.2",
|
|
65
63
|
"vitepress-plugin-twoslash": "^0.10.2"
|
|
66
64
|
},
|
|
67
65
|
"devDependencies": {
|
|
68
66
|
"@stacksjs/development": "latest",
|
|
69
|
-
"@vite-pwa/vitepress": "^0.
|
|
67
|
+
"@vite-pwa/vitepress": "^0.5.0"
|
|
70
68
|
}
|
|
71
69
|
}
|
package/src/index.ts
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
import { defineConfig } from 'vitepress'
|
|
2
|
-
import type { UserConfig } from 'vitepress'
|
|
3
1
|
import { alias } from '@stacksjs/alias'
|
|
4
|
-
import {
|
|
2
|
+
import { kolorist as c } from '@stacksjs/cli'
|
|
5
3
|
import { docs } from '@stacksjs/config'
|
|
4
|
+
import { path as p } from '@stacksjs/path'
|
|
6
5
|
import { server } from '@stacksjs/server'
|
|
7
|
-
import { kolorist as c } from '@stacksjs/cli'
|
|
8
6
|
import { withPwa } from '@vite-pwa/vitepress'
|
|
9
|
-
import {
|
|
7
|
+
import { defineConfig } from 'vitepress'
|
|
8
|
+
import type { UserConfig } from 'vitepress'
|
|
9
|
+
import { version } from '../package.json'
|
|
10
10
|
import { pwaDocs as pwa } from './scripts/pwa'
|
|
11
11
|
|
|
12
12
|
export const frameworkDefaults = {
|
|
@@ -38,13 +38,11 @@ export const frameworkDefaults = {
|
|
|
38
38
|
configureServer(server) {
|
|
39
39
|
// const base = server.config.base || '/'
|
|
40
40
|
// const _print = server.printUrls
|
|
41
|
-
server.printUrls = () => {
|
|
41
|
+
server.printUrls = () => {
|
|
42
42
|
console.log(` ${c.blue(c.bold('STACKS'))} ${c.blue(version)}`)
|
|
43
43
|
|
|
44
44
|
// console.log(` ${c.green('➜')} ${c.bold('Docs')}: ${c.green('http://stacks.localhost:3000/docs')}`)
|
|
45
|
-
// eslint-disable-next-line no-console
|
|
46
45
|
console.log(` ${c.green('➜')} ${c.bold('Docs')}: ${c.green('https://stacks.localhost/docs')}`)
|
|
47
|
-
// eslint-disable-next-line no-console
|
|
48
46
|
console.log(` ${c.green('➜')} ${c.bold('Temp URL')}: ${c.green('http://stacksjs.test:3000')}`)
|
|
49
47
|
}
|
|
50
48
|
},
|
package/src/meta.ts
CHANGED
|
@@ -28,5 +28,4 @@ export const preconnectHomeLinks = [googleapis, gstatic]
|
|
|
28
28
|
/* PWA runtime caching urlPattern regular expressions */
|
|
29
29
|
export const pwaFontsRegex = new RegExp(`^${googleapis}/.*`, 'i')
|
|
30
30
|
export const pwaFontStylesRegex = new RegExp(`^${gstatic}/.*`, 'i')
|
|
31
|
-
|
|
32
|
-
export const githubusercontentRegex = new RegExp('^https://((i.ibb.co)|((raw|user-images).githubusercontent.com))/.*', 'i')
|
|
31
|
+
export const githubusercontentRegex = /^https:\/\/((i.ibb.co)|((raw|user-images).githubusercontent.com))\/.*/i
|
package/src/plugins.ts
CHANGED
package/src/scripts/pwa.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
+
import { docs } from '@stacksjs/config'
|
|
1
2
|
import { frameworkPath } from '@stacksjs/path'
|
|
2
3
|
import type { PwaOptions } from '@vite-pwa/vitepress'
|
|
3
|
-
import { docs } from '@stacksjs/config'
|
|
4
4
|
import { githubusercontentRegex, pwaFontStylesRegex, pwaFontsRegex } from '../meta'
|
|
5
5
|
|
|
6
6
|
export const pwaDocs: PwaOptions = {
|
|
@@ -44,12 +44,14 @@ export const pwaDocs: PwaOptions = {
|
|
|
44
44
|
purpose: 'maskable',
|
|
45
45
|
},
|
|
46
46
|
],
|
|
47
|
-
screenshots: [
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
47
|
+
screenshots: [
|
|
48
|
+
{
|
|
49
|
+
src: 'og.png',
|
|
50
|
+
sizes: '2258x1185',
|
|
51
|
+
type: 'image/png',
|
|
52
|
+
label: `Screenshot of ${docs.title}`,
|
|
53
|
+
},
|
|
54
|
+
],
|
|
53
55
|
handle_links: 'preferred',
|
|
54
56
|
launch_handler: {
|
|
55
57
|
client_mode: ['navigate-existing', 'auto'],
|
package/dist/index.d.ts
DELETED
|
@@ -1,26 +0,0 @@
|
|
|
1
|
-
export declare const frameworkDefaults: {
|
|
2
|
-
base: string;
|
|
3
|
-
cleanUrls: true;
|
|
4
|
-
srcDir: any;
|
|
5
|
-
outDir: any;
|
|
6
|
-
cacheDir: any;
|
|
7
|
-
assetsDir: any;
|
|
8
|
-
vite: {
|
|
9
|
-
envDir: any;
|
|
10
|
-
envPrefix: string;
|
|
11
|
-
server: any;
|
|
12
|
-
resolve: {
|
|
13
|
-
alias: any;
|
|
14
|
-
};
|
|
15
|
-
plugins: {
|
|
16
|
-
name: string;
|
|
17
|
-
configureServer(this: void, server: import("vite").ViteDevServer): void;
|
|
18
|
-
}[];
|
|
19
|
-
};
|
|
20
|
-
pwa: import("@vite-pwa/vitepress").PwaOptions;
|
|
21
|
-
};
|
|
22
|
-
declare const _default: Promise<any>;
|
|
23
|
-
export default _default;
|
|
24
|
-
export * from './plugins';
|
|
25
|
-
export * from './scripts/pwa';
|
|
26
|
-
export * from './meta';
|
package/dist/meta.d.ts
DELETED
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
export declare const googleapis = "https://fonts.googleapis.com";
|
|
2
|
-
export declare const gstatic = "https://fonts.gstatic.com";
|
|
3
|
-
export declare const font = "https://fonts.googleapis.com/css2?family=Readex+Pro:wght@200;400;600&display=swap";
|
|
4
|
-
export declare const ogUrl = "https://stacksjs.org/";
|
|
5
|
-
export declare const ogImage = "https://stacksjs.org/og.png";
|
|
6
|
-
export declare const github = "https://github.com/stacksjs/stacks";
|
|
7
|
-
export declare const releases = "https://github.com/stacksjs/stacks/releases";
|
|
8
|
-
export declare const contributing = "https://github.com/stacksjs/stacks/blob/main/CONTRIBUTING.md";
|
|
9
|
-
export declare const discord = "https://chat.stacksjs.org";
|
|
10
|
-
export declare const twitter = "https://twitter.com/stacksjs";
|
|
11
|
-
export declare const preconnectLinks: string[];
|
|
12
|
-
export declare const preconnectHomeLinks: string[];
|
|
13
|
-
export declare const pwaFontsRegex: RegExp;
|
|
14
|
-
export declare const pwaFontStylesRegex: RegExp;
|
|
15
|
-
export declare const githubusercontentRegex: RegExp;
|
package/dist/plugins.d.ts
DELETED
package/dist/scripts/pwa.d.ts
DELETED