@vitnode/core 1.2.0-canary.65 → 1.2.0-canary.67
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.
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type { VitNodeApiConfig, VitNodeConfig } from "../src/vitnode.config";
|
|
1
|
+
import type { VitNodeApiConfig, VitNodeConfig } from "../src/vitnode.config.js";
|
|
2
2
|
type ConfigType<T extends "api.config" | "config"> = T extends "config" ? VitNodeConfig : VitNodeApiConfig;
|
|
3
3
|
export declare const getConfig: <T extends "api.config" | "config">({ type, }: {
|
|
4
4
|
type?: T;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"get-config.d.ts","sourceRoot":"","sources":["../../scripts/get-config.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAE,gBAAgB,EAAE,aAAa,EAAE,MAAM,
|
|
1
|
+
{"version":3,"file":"get-config.d.ts","sourceRoot":"","sources":["../../scripts/get-config.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAE,gBAAgB,EAAE,aAAa,EAAE,MAAM,0BAA0B,CAAC;AAEhF,KAAK,UAAU,CAAC,CAAC,SAAS,YAAY,GAAG,QAAQ,IAAI,CAAC,SAAS,QAAQ,GACnE,aAAa,GACb,gBAAgB,CAAC;AAErB,eAAO,MAAM,SAAS,GAAU,CAAC,SAAS,YAAY,GAAG,QAAQ,EAAE,WAEhE;IACD,IAAI,CAAC,EAAE,CAAC,CAAC;CACV,KAAG,OAAO,CAAC,UAAU,CAAC,CAAC,CAAC,CAaxB,CAAC"}
|
package/dist/scripts/plugin.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import chokidar from "chokidar";
|
|
2
2
|
import { existsSync, mkdirSync, readdirSync, readFileSync, unlinkSync, } from "node:fs";
|
|
3
3
|
import { basename, join, relative } from "node:path";
|
|
4
|
-
import { buildInitialRouteMap, copyFile, findLocaleRoot, findRepoRoot, getAllFiles, isDirectoryEmpty, routeKey, } from "./shared/file-utils";
|
|
4
|
+
import { buildInitialRouteMap, copyFile, findLocaleRoot, findRepoRoot, getAllFiles, isDirectoryEmpty, routeKey, } from "./shared/file-utils.js";
|
|
5
5
|
const detectAppType = (appPath) => {
|
|
6
6
|
const hasWebConfig = existsSync(join(appPath, "src", "vitnode.config.ts"));
|
|
7
7
|
const hasApiConfig = existsSync(join(appPath, "src", "vitnode.api.config.ts"));
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { existsSync, readdirSync } from "node:fs";
|
|
2
2
|
import { readFile } from "node:fs/promises";
|
|
3
3
|
import { join, relative } from "node:path";
|
|
4
|
-
import { getConfig } from "./get-config";
|
|
5
|
-
import { buildInitialRouteMap, copyDirectoryRecursive, findLocaleRoot, findRepoRoot, isDirectoryEmpty, } from "./shared/file-utils";
|
|
4
|
+
import { getConfig } from "./get-config.js";
|
|
5
|
+
import { buildInitialRouteMap, copyDirectoryRecursive, findLocaleRoot, findRepoRoot, isDirectoryEmpty, } from "./shared/file-utils.js";
|
|
6
6
|
export const preparePluginsFiles = async (flag) => {
|
|
7
7
|
const cwd = process.cwd();
|
|
8
8
|
const hasWebConfig = existsSync(join(cwd, "src", "vitnode.config.ts"));
|