Skip to content

Commit 18fffb2

Browse files
committed
fix(cli-template): babel.config.js at dist-h5 not work for serve h5
1 parent ec3ee54 commit 18fffb2

File tree

2 files changed

+14
-8
lines changed

2 files changed

+14
-8
lines changed

packages/mars-cli-template/generator/dist-h5/babel.config.js

Lines changed: 0 additions & 8 deletions
This file was deleted.
Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
/* eslint-disable */
2+
const target = process.env.MARS_CLI_TARGET || 'swan';
3+
let config = {};
4+
5+
// babel config for H5
6+
if (target === 'h5') {
7+
config = {
8+
presets: [
9+
'@vue/app'
10+
]
11+
};
12+
}
13+
14+
module.exports = config;

0 commit comments

Comments
 (0)