From d6cd14a6f0fbd33454045c7729f77ad242dcfb04 Mon Sep 17 00:00:00 2001 From: Hermann Rolfes Date: Wed, 28 Feb 2024 10:04:15 +0100 Subject: [PATCH] Add banner for single-file ESM bundles + fixing type error (#6095) --- utils/rollup-build-target.mjs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/utils/rollup-build-target.mjs b/utils/rollup-build-target.mjs index 4dddabe7e01..2653a7d3ade 100644 --- a/utils/rollup-build-target.mjs +++ b/utils/rollup-build-target.mjs @@ -120,7 +120,7 @@ function buildTarget(buildType, moduleFormat, input = 'src/index.js', buildDir = }; /** @type {OutputOptions} */ const outputOptions = { - banner: moduleFormat === 'es5' && getBanner(banner[buildType]), + banner: (moduleFormat === 'es5' || shouldBundle) ? getBanner(banner[buildType]) : undefined, plugins: outputPlugins[buildType || outputPlugins.release], format: outputFormat[moduleFormat], indent: '\t',