UNPKG

444 BJavaScriptView Raw
1module.exports = function shopifyNonStandardPlugins(options = {}) {
2 const {inlineEnv = false} = options;
3
4 const plugins = [
5 [
6 require.resolve('@babel/plugin-transform-runtime'),
7 {
8 helpers: true,
9 polyfill: false,
10 regenerator: true,
11 },
12 ],
13 ];
14
15 if (inlineEnv) {
16 plugins.push(
17 require.resolve('babel-plugin-transform-inline-environment-variables')
18 );
19 }
20
21 return plugins;
22};