I use aldeed:collection2 or aldeed:schema-deny for collections. It work fine with run dev, but got the follow error when build app:
Errors prevented bundling:
While minifying app code:
packages/minifyStdJS/plugin/minify-js.js:49:25: terser minification error (SyntaxError:"Import" statement may only appear at the top level)
Source file: node_modules/simpl-schema/dist/esm/validation/typeValidator/index.js (2:0)
Line content: import { SimpleSchema } from '../../SimpleSchema.js';
at maybeThrowMinifyErrorBySourceFile (packages/minifyStdJS/plugin/minify-js.js:49:25)
at packages/minifyStdJS/plugin/minify-js.js:77:11
at Array.forEach (<anonymous>)
at MeteorMinifier.processFilesForBundle (packages/minifyStdJS/plugin/minify-js.js:66:11)
While minifying app code:
packages/minifyStdJS/plugin/minify-js.js:49:25: terser minification error (SyntaxError:"Import" statement may only appear at the top level)
Source file: node_modules/mongo-object/dist/index.js (2:0)
Line content: import MongoObject from './mongo-object.js';
at maybeThrowMinifyErrorBySourceFile (packages/minifyStdJS/plugin/minify-js.js:49:25)
at packages/minifyStdJS/plugin/minify-js.js:77:11
at Array.forEach (<anonymous>)
at MeteorMinifier.processFilesForBundle (packages/minifyStdJS/plugin/minify-js.js:66:11)
I use aldeed:collection2 or aldeed:schema-deny for collections. It work fine with run dev, but got the follow error when build app: