We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent c0cf355 commit d70d4efCopy full SHA for d70d4ef
scripts/prepack.ts
@@ -91,10 +91,16 @@ try {
91
async function runPackagePrepack(packagePrepackPath: string): Promise<void> {
92
const { prepack } = await import(packagePrepackPath);
93
if (prepack && typeof prepack === 'function') {
94
- const success = prepack(buildDir);
95
- if (!success) {
+ const isScuccess = prepack(buildDir);
+ if (!isScuccess) {
96
process.exit(1);
97
}
98
+ } else {
99
+ console.error(`Could not find a prepack function in ${packagePrepackPath}.`);
100
+ console.error(
101
+ 'Make sure, your package-specific prepack script exports `function prepack(buildDir: string): boolean`.',
102
+ );
103
+ process.exit(1);
104
105
106
0 commit comments