From f7f376f91e4ef8fe9ddcfca7e871cf8195d5894c Mon Sep 17 00:00:00 2001 From: JJ Kasper Date: Mon, 28 Sep 2020 18:47:05 -0500 Subject: [PATCH] Ensure optional-chaining/nullish coalescing is included (#17429) --- packages/next/build/babel/preset.ts | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/packages/next/build/babel/preset.ts b/packages/next/build/babel/preset.ts index e4a4c660cc..8e660e7e02 100644 --- a/packages/next/build/babel/preset.ts +++ b/packages/next/build/babel/preset.ts @@ -79,6 +79,10 @@ module.exports = ( // In production/development this option is set to `false` so that webpack can handle import/export with tree-shaking modules: 'auto', exclude: ['transform-typeof-symbol'], + include: [ + '@babel/plugin-proposal-optional-chaining', + '@babel/plugin-proposal-nullish-coalescing-operator', + ], ...options['preset-env'], } -- GitLab