-
-
Notifications
You must be signed in to change notification settings - Fork 4.2k
Expand file tree
/
Copy pathbabel.test.config.mjs
More file actions
31 lines (25 loc) · 821 Bytes
/
babel.test.config.mjs
File metadata and controls
31 lines (25 loc) · 821 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
/*
This babel config governs Ember's test suite. It transpiles some things that
our published build should not (because those things are left for apps to
decide).
See babel.config.mjs for the base config that's used for building for
publication.
*/
import { createRequire } from 'node:module';
import baseConfig from './babel.config.mjs';
// eslint-disable-next-line no-redeclare
const require = createRequire(import.meta.url);
const buildDebugMacroPlugin = require('./broccoli/build-debug-macro-plugin.js');
const isProduction = process.env.EMBER_ENV === 'production';
export default {
...baseConfig,
presets: [
[
'@babel/preset-env',
{
targets: require('./config/targets.js'),
},
],
],
plugins: [...baseConfig.plugins, buildDebugMacroPlugin(!isProduction)],
};