From c2e5513c79dea522f473d94a37b412f806cd3fe7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Fran=C3=A7ois=20Chalifour?= Date: Wed, 26 Aug 2020 10:18:05 +0200 Subject: [PATCH] chore(build): add banner to all builds --- rollup.config.js | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/rollup.config.js b/rollup.config.js index c0fd93d4..93b1575d 100644 --- a/rollup.config.js +++ b/rollup.config.js @@ -1,4 +1,10 @@ import { plugins } from '../../rollup.base.config'; +import { checkIsReleaseReady } from '../scripts/checkIsReleaseReady'; +import { getBundleBanner } from '../scripts/getBundleBanner'; + +import pkg from './package.json'; + +checkIsReleaseReady(); if (!process.env.BUILD) { throw new Error('The `BUILD` environment variable is required to build.'); @@ -10,11 +16,13 @@ const output = { format: 'umd', sourcemap: true, name: 'docsearch', + banner: getBundleBanner(pkg), }, esm: { file: 'dist/esm/index.js', format: 'es', sourcemap: true, + banner: getBundleBanner(pkg), }, };