@brillout/docpress 0.5.11 → 0.5.12

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.
@@ -8,7 +8,7 @@ import {
8
8
  // src/vite.config.ts
9
9
  import mdx from "@mdx-js/rollup";
10
10
  import react from "@vitejs/plugin-react-swc";
11
- import ssr from "vite-plugin-ssr/plugin";
11
+ import ssr from "vike/plugin";
12
12
 
13
13
  // src/markdownHeadingsVitePlugin.ts
14
14
  import os from "os";
package/dist/cli/index.js CHANGED
@@ -1,13 +1,13 @@
1
1
  import {
2
2
  vite_config_default
3
- } from "../chunk-W5PDEMRM.js";
3
+ } from "../chunk-PHRTR4OU.js";
4
4
  import "../chunk-OFUQWIQL.js";
5
5
  import "../chunk-2ZTPUQGS.js";
6
6
  import "../chunk-3QC7HYIF.js";
7
7
 
8
8
  // src/cli/index.ts
9
9
  import { build, preview } from "vite";
10
- import { prerender } from "vite-plugin-ssr/prerender";
10
+ import { prerender } from "vike/prerender";
11
11
  var args = process.argv.filter(Boolean).slice(2);
12
12
  var isDev = args.includes("dev");
13
13
  var isPreview = args.includes("preview");
@@ -16,7 +16,7 @@ Error.stackTraceLimit = Infinity;
16
16
  cli();
17
17
  async function cli() {
18
18
  if (isDev) {
19
- await import("../devServer-5TMJUDWP.js");
19
+ await import("../devServer-QUFP2E4K.js");
20
20
  } else if (isBuild) {
21
21
  await build(vite_config_default);
22
22
  await build({ ...vite_config_default, build: { ssr: true } });
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  vite_config_default
3
- } from "./chunk-W5PDEMRM.js";
3
+ } from "./chunk-PHRTR4OU.js";
4
4
  import "./chunk-OFUQWIQL.js";
5
5
  import "./chunk-2ZTPUQGS.js";
6
6
  import "./chunk-3QC7HYIF.js";
@@ -8,7 +8,7 @@ import "./chunk-3QC7HYIF.js";
8
8
  // src/cli/devServer.ts
9
9
  import express from "express";
10
10
  import * as vite from "vite";
11
- import { renderPage } from "vite-plugin-ssr/server";
11
+ import { renderPage } from "vike/server";
12
12
  var viteVersion = vite.version || "2.?.?";
13
13
  startServer();
14
14
  async function startServer() {
package/dist/index.d.ts CHANGED
@@ -67,17 +67,17 @@ type Config = {
67
67
  twitterProfile: string;
68
68
  };
69
69
  faviconUrl: string;
70
- algolia: null | {
71
- PENDING_APPROVAL: true;
70
+ algolia: null | ({
71
+ PENDING_APPROVAL?: true;
72
+ } & ({
72
73
  appId?: undefined;
73
74
  apiKey?: undefined;
74
75
  indexName?: undefined;
75
76
  } | {
76
- PENDING_APPROVAL?: undefined;
77
77
  appId: string;
78
78
  apiKey: string;
79
79
  indexName: string;
80
- };
80
+ }));
81
81
  headings: HeadingDefinition[];
82
82
  headingsDetached: HeadingDetachedDefinition[];
83
83
  navHeaderMobile: React.ReactNode;
@@ -1,5 +1,5 @@
1
- import * as vite_plugin_ssr_dist_types_node_runtime_html_renderHtml from 'vite-plugin-ssr/dist/types/node/runtime/html/renderHtml';
2
- import { PageContextBuiltIn } from 'vite-plugin-ssr/types';
1
+ import * as vike_dist_esm_node_runtime_html_renderHtml from 'vike/dist/esm/node/runtime/html/renderHtml';
2
+ import { PageContextBuiltIn } from 'vike/types';
3
3
 
4
4
  type MarkdownHeading = {
5
5
  title: string;
@@ -17,6 +17,6 @@ type PageContextOriginal = PageContextBuiltIn & {
17
17
  exports: Exports;
18
18
  };
19
19
 
20
- declare function render(pageContextOriginal: PageContextOriginal): Promise<vite_plugin_ssr_dist_types_node_runtime_html_renderHtml.TemplateWrapped>;
20
+ declare function render(pageContextOriginal: PageContextOriginal): Promise<vike_dist_esm_node_runtime_html_renderHtml.TemplateWrapped>;
21
21
 
22
22
  export { render };
@@ -22,7 +22,7 @@ import {
22
22
  // src/renderer/_default.page.server.tsx
23
23
  import ReactDOMServer from "react-dom/server";
24
24
  import React7 from "react";
25
- import { escapeInject as escapeInject2, dangerouslySkipEscape as dangerouslySkipEscape2 } from "vite-plugin-ssr/server";
25
+ import { escapeInject as escapeInject2, dangerouslySkipEscape as dangerouslySkipEscape2 } from "vike/server";
26
26
 
27
27
  // src/PageLayout.tsx
28
28
  import React6 from "react";
@@ -562,7 +562,7 @@ function getPageHeadings(pageContext, currentHeading) {
562
562
  }
563
563
 
564
564
  // src/algolia/DocSearch.ts
565
- import { dangerouslySkipEscape, escapeInject } from "vite-plugin-ssr/server";
565
+ import { dangerouslySkipEscape, escapeInject } from "vike/server";
566
566
  function getDocSearchCSS(pageContext) {
567
567
  const docSearchCSS = !pageContext.meta.algolia ? "" : escapeInject`
568
568
  <link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/@docsearch/css@alpha" />
@@ -578,7 +578,7 @@ function getDocSearchJS(pageContext) {
578
578
  const appId = '`, "';\n const apiKey = '", "';\n const indexName = '", "';\n const transformItems = ", ";\n docsearch({\n container: '#docsearch-desktop',\n appId, apiKey, indexName, transformItems\n });\n docsearch({\n container: '#docsearch-mobile',\n appId, apiKey, indexName, transformItems\n });\n <\/script>\n "])), algolia.appId || "FAKE", algolia.apiKey || "FAKE", algolia.indexName || "FAKE", dangerouslySkipEscape(getTransformItems()));
579
579
  if (algolia == null ? void 0 : algolia.PENDING_APPROVAL) {
580
580
  docSearchJS = escapeInject(_b || (_b = __template(["\n ", `
581
- <script>[document.getElementById('docsearch-desktop'), document.getElementById('docsearch-mobile')].forEach(el => el.addEventListener('click', () => window.alert("Algolia approval is pending: the search results will be empty. Try again in a couple of days.")))<\/script>
581
+ <script>[document.getElementById('docsearch-desktop'), document.getElementById('docsearch-mobile')].forEach(el => el.addEventListener('click', () => window.alert("Algolia approval is pending: the search results may be empty until the approval process is completed.")))<\/script>
582
582
  `])), docSearchJS);
583
583
  }
584
584
  return docSearchJS;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@brillout/docpress",
3
- "version": "0.5.11",
3
+ "version": "0.5.12",
4
4
  "scripts": {
5
5
  "// Check types while developing": "",
6
6
  "types": "tsc --noEmit --watch",
@@ -26,7 +26,7 @@
26
26
  "shiki": "^0.10.1",
27
27
  "twemoji": "^13.1.0",
28
28
  "vite": "^4.3.9",
29
- "vite-plugin-ssr": "^0.4.131"
29
+ "vike": "^0.4.131"
30
30
  },
31
31
  "type": "module",
32
32
  "exports": {
package/readme.md CHANGED
@@ -1,5 +1,5 @@
1
1
  # `@brillout/docpress`
2
2
 
3
- Doc generator for `https://vite-plugin-ssr.com` and `https://telefunc.com`.
3
+ Doc generator for `https://vike.dev` and `https://telefunc.com`.
4
4
 
5
5
  Don't use this: consider `@brillout/docpress` private use only.