Skip to content

Commit cb52fdb

Browse files
committed
fix(scripts): resolve target types error in build-shared.js
1 parent 22c4a3d commit cb52fdb

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

scripts/build-shared.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ const require = createRequire(import.meta.url)
77
* @param {Object} options
88
* @param {any} options.pkg - Package.json object
99
* @param {string} options.format - Build format
10-
* @param {string} options.target - Target package name
10+
* @param {string|undefined} options.target - Target package name
1111
* @param {boolean} options.isGlobalBuild - Whether this is a global build
1212
* @param {boolean} options.isBrowserESMBuild - Whether this is a browser ESM build
1313
* @param {boolean} options.isCompatPackage - Whether this is the compat package
@@ -17,7 +17,7 @@ const require = createRequire(import.meta.url)
1717
export function resolveExternal({
1818
pkg,
1919
format,
20-
target,
20+
target = '',
2121
isGlobalBuild = false,
2222
isBrowserESMBuild = false,
2323
isCompatPackage = false,
@@ -91,7 +91,7 @@ export function getConsolidateDeps() {
9191

9292
/**
9393
* Resolve compiler ignore list for CommonJS
94-
* @param {string} target - Target package name
94+
* @param {string|undefined} target - Target package name
9595
* @returns {string[]}
9696
*/
9797
export function resolveCJSIgnores(target) {

0 commit comments

Comments
 (0)