vite-plugin-lib 2.0.0 → 2.0.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/dist/index.mjs +5 -1
- package/package.json +1 -1
package/dist/index.mjs
CHANGED
|
@@ -164,6 +164,7 @@ function buildConfig({
|
|
|
164
164
|
external: externalPackages ?? [
|
|
165
165
|
/node_modules/,
|
|
166
166
|
...builtinModules,
|
|
167
|
+
/node:/,
|
|
167
168
|
...getDependencies(manifest)
|
|
168
169
|
]
|
|
169
170
|
}
|
|
@@ -265,7 +266,10 @@ function library(options = {}) {
|
|
|
265
266
|
include: `${path.resolve(mergedOptions.entry, "..")}/**`,
|
|
266
267
|
outDir: typesDir,
|
|
267
268
|
staticImport: true,
|
|
268
|
-
afterBuild: includesESFormat(
|
|
269
|
+
afterBuild: includesESFormat(mergedOptions.formats) ? () => generateMTSDeclarations(
|
|
270
|
+
typesDir,
|
|
271
|
+
mergedOptions.formats?.length === 1
|
|
272
|
+
) : void 0
|
|
269
273
|
})
|
|
270
274
|
];
|
|
271
275
|
}
|
package/package.json
CHANGED