@brillout/vite-plugin-server-entry
Advanced tools
Comparing version 0.5.5 to 0.5.6
export { debugLogsBuildtime }; | ||
declare function debugLogsBuildtime({ disabled, paths }: { | ||
declare function debugLogsBuildtime({ disabled, paths, }: { | ||
disabled: true; | ||
@@ -4,0 +4,0 @@ paths: null; |
@@ -5,3 +5,3 @@ "use strict"; | ||
const debug_1 = require("../shared/debug"); | ||
function debugLogsBuildtime({ disabled, paths }) { | ||
function debugLogsBuildtime({ disabled, paths, }) { | ||
if (!debug_1.DEBUG) | ||
@@ -8,0 +8,0 @@ return; |
@@ -12,2 +12,3 @@ "use strict"; | ||
const debugLogsBuildTime_1 = require("./debugLogsBuildTime"); | ||
const rollupSourceMap_1 = require("../utils/rollupSourceMap"); | ||
const autoImporterFilePath = require.resolve('../runtime/autoImporter.js'); | ||
@@ -111,10 +112,6 @@ const serverEntryVirtualId = 'virtual:@brillout/vite-plugin-server-entry:serverEntry'; | ||
`import '${serverEntryVirtualId}';`, | ||
code | ||
].join('' | ||
/* We don't insert new lines, otherwise we break the source map. | ||
'\n' | ||
*/ | ||
); | ||
return code; | ||
} | ||
code, | ||
].join(''); | ||
return (0, rollupSourceMap_1.sourceMapPassthrough)(code); | ||
}, | ||
}, | ||
@@ -135,4 +132,4 @@ { | ||
library = resolved.library; | ||
} | ||
} | ||
}, | ||
}, | ||
]; | ||
@@ -156,3 +153,3 @@ } | ||
autoImport: true, | ||
inject: false | ||
inject: false, | ||
}; | ||
@@ -164,7 +161,7 @@ setInjectConfig(pluginConfigResolved, pluginConfigProvidedByLibrary.inject); | ||
pluginVersion: utils_1.projectInfo.projectVersion, | ||
apiVersion | ||
apiVersion, | ||
}; | ||
pluginConfigResolved.libraries.push(library); | ||
(0, utils_1.objectAssign)(configUnresolved, { | ||
_vitePluginServerEntry: pluginConfigResolved | ||
_vitePluginServerEntry: pluginConfigResolved, | ||
}); | ||
@@ -224,3 +221,3 @@ const config = configUnresolved; | ||
return entryCode; | ||
}) | ||
}), | ||
].join('\n'); | ||
@@ -247,3 +244,3 @@ return serverProductionEntry; | ||
'};', | ||
'' | ||
'', | ||
].join('\n')); | ||
@@ -320,3 +317,3 @@ } | ||
disabled: false, | ||
paths: { importerDir, root, rootRelative, outDir, distServerPathRelative, distServerPathAbsolute } | ||
paths: { importerDir, root, rootRelative, outDir, distServerPathRelative, distServerPathAbsolute }, | ||
}); | ||
@@ -368,3 +365,3 @@ return { distServerPathRelative, distServerPathAbsolute }; | ||
serverEntryFileNameBase_1.serverEntryFileNameBase, | ||
serverEntryFileNameBase_1.serverEntryFileNameBaseAlternative | ||
serverEntryFileNameBase_1.serverEntryFileNameBaseAlternative, | ||
], Object.keys(bundle))); | ||
@@ -402,3 +399,3 @@ return entry; | ||
`Make sure your Vite config (or that of a Vite plugin) doesn't remove/overwrite server build entries.`, | ||
`(Found server entries: ${list(entriesExisting)}.)` | ||
`(Found server entries: ${list(entriesExisting)}.)`, | ||
].join(' '); | ||
@@ -405,0 +402,0 @@ } |
@@ -61,3 +61,3 @@ "use strict"; | ||
`${serverEntryFileNameBase_1.serverIndexFileNameBase}.js`, | ||
`${serverEntryFileNameBase_1.serverIndexFileNameBase}.cjs` | ||
`${serverEntryFileNameBase_1.serverIndexFileNameBase}.cjs`, | ||
]; | ||
@@ -64,0 +64,0 @@ for (const distFileName of distFileNames) { |
@@ -5,3 +5,3 @@ export { debugLogsRuntimePre }; | ||
declare function debugLogsRuntimePre(autoImporter: AutoImporter): undefined | void; | ||
declare function debugLogsRuntimePost({ success, requireError, outDir, isOutsideOfCwd }: { | ||
declare function debugLogsRuntimePost({ success, requireError, outDir, isOutsideOfCwd, }: { | ||
success: boolean; | ||
@@ -8,0 +8,0 @@ requireError: unknown; |
@@ -47,3 +47,3 @@ "use strict"; | ||
} | ||
function debugLogsRuntimePost({ success, requireError, outDir, isOutsideOfCwd }) { | ||
function debugLogsRuntimePost({ success, requireError, outDir, isOutsideOfCwd, }) { | ||
if (!debug_1.DEBUG) | ||
@@ -50,0 +50,0 @@ return; |
export { importServerProductionEntry }; | ||
declare function importServerProductionEntry({ tolerateNotFound, outDir }?: { | ||
declare function importServerProductionEntry({ tolerateNotFound, outDir, }?: { | ||
tolerateNotFound?: boolean; | ||
outDir?: string; | ||
}): Promise<null | boolean>; |
@@ -10,3 +10,3 @@ "use strict"; | ||
// Usage by Telefunc since Telefunc cannot assume/know whether the user is using Vite | ||
tolerateNotFound, outDir } = {}) { | ||
tolerateNotFound, outDir, } = {}) { | ||
const autoImporter = require('./autoImporter.js'); | ||
@@ -13,0 +13,0 @@ (0, debugLogsRuntime_1.debugLogsRuntimePre)(autoImporter); |
@@ -6,1 +6,2 @@ export * from '../utils/assert'; | ||
export * from '../utils/isWebpackResolve'; | ||
export * from '../utils/rollupSourceMap'; |
@@ -22,1 +22,2 @@ "use strict"; | ||
__exportStar(require("../utils/isWebpackResolve"), exports); | ||
__exportStar(require("../utils/rollupSourceMap"), exports); |
export { assert }; | ||
export { assertUsage }; | ||
export { logLabel }; | ||
declare const logLabel: "[@brillout/vite-plugin-server-entry@0.5.5]"; | ||
declare const logLabel: "[@brillout/vite-plugin-server-entry@0.5.6]"; | ||
declare function assert(condition: unknown, debugInfo?: unknown): asserts condition; | ||
declare function assertUsage(condition: unknown, errorMessage: string): asserts condition; |
@@ -29,3 +29,3 @@ "use strict"; | ||
`Don't hesitate to reach out as it makes ${projectInfo_1.projectInfo.projectName} more robust.`, | ||
debugStr | ||
debugStr, | ||
] | ||
@@ -32,0 +32,0 @@ .filter(Boolean) |
@@ -11,3 +11,3 @@ "use strict"; | ||
...inputsNew, | ||
...inputsCurrent | ||
...inputsCurrent, | ||
}; | ||
@@ -14,0 +14,0 @@ return input; |
@@ -1,1 +0,1 @@ | ||
export declare const PROJECT_VERSION: "0.5.5"; | ||
export declare const PROJECT_VERSION: "0.5.6"; |
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
exports.PROJECT_VERSION = void 0; | ||
exports.PROJECT_VERSION = '0.5.5'; | ||
exports.PROJECT_VERSION = '0.5.6'; |
export declare const projectInfo: { | ||
projectName: "@brillout/vite-plugin-server-entry"; | ||
npmPackageName: "@brillout/vite-plugin-server-entry"; | ||
projectVersion: "0.5.5"; | ||
projectVersion: "0.5.6"; | ||
githubRepository: "https://github.com/brillout/vite-plugin-server-entry"; | ||
}; |
@@ -9,3 +9,3 @@ "use strict"; | ||
projectVersion: PROJECT_VERSION_1.PROJECT_VERSION, | ||
githubRepository: 'https://github.com/brillout/vite-plugin-server-entry' | ||
githubRepository: 'https://github.com/brillout/vite-plugin-server-entry', | ||
}; |
{ | ||
"name": "@brillout/vite-plugin-server-entry", | ||
"version": "0.5.5", | ||
"version": "0.5.6", | ||
"repository": "https://github.com/brillout/vite-plugin-server-entry", | ||
@@ -5,0 +5,0 @@ "dependencies": { |
58297
60
1190