Skip to content

Commit 509c5b4

Browse files
authored
Disable babel compact option (home-assistant#9335)
1 parent e00bcc9 commit 509c5b4

File tree

3 files changed

+1
-8
lines changed

3 files changed

+1
-8
lines changed

build-scripts/bundle.js

+1-6
Original file line numberDiff line numberDiff line change
@@ -52,6 +52,7 @@ module.exports.terserOptions = (latestBuild) => ({
5252

5353
module.exports.babelOptions = ({ latestBuild }) => ({
5454
babelrc: false,
55+
compact: false,
5556
presets: [
5657
!latestBuild && [
5758
"@babel/preset-env",
@@ -79,12 +80,6 @@ module.exports.babelOptions = ({ latestBuild }) => ({
7980
].filter(Boolean),
8081
});
8182

82-
// Are already ES5, cause warnings when babelified.
83-
module.exports.babelExclude = () => [
84-
require.resolve("@mdi/js/mdi.js"),
85-
require.resolve("hls.js"),
86-
];
87-
8883
const outputPath = (outputRoot, latestBuild) =>
8984
path.resolve(outputRoot, latestBuild ? "frontend_latest" : "frontend_es5");
9085

build-scripts/rollup.js

-1
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,6 @@ const createRollupConfig = ({
5757
babel({
5858
...bundle.babelOptions({ latestBuild }),
5959
extensions,
60-
exclude: bundle.babelExclude(),
6160
babelHelpers: isWDS ? "inline" : "bundled",
6261
}),
6362
string({

build-scripts/webpack.js

-1
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,6 @@ const createWebpackConfig = ({
4747
rules: [
4848
{
4949
test: /\.m?js$|\.ts$/,
50-
exclude: bundle.babelExclude(),
5150
use: {
5251
loader: "babel-loader",
5352
options: bundle.babelOptions({ latestBuild }),

0 commit comments

Comments
 (0)