Commit da947224 authored by Luis Fernando Alvarez D's avatar Luis Fernando Alvarez D Committed by Tim Neutkens

Remove prop-types import in the build (#6798)

Tests don't catch this change because `isProduction &&` is always false so I tested it with a local build
parent 99362592
...@@ -85,7 +85,9 @@ module.exports = (api: any, options: NextBabelPresetOptions = {}): BabelPreset = ...@@ -85,7 +85,9 @@ module.exports = (api: any, options: NextBabelPresetOptions = {}): BabelPreset =
}], }],
[require('styled-jsx/babel'), styledJsxOptions(options['styled-jsx'])], [require('styled-jsx/babel'), styledJsxOptions(options['styled-jsx'])],
require('./plugins/amp-attributes'), require('./plugins/amp-attributes'),
isProduction && require('babel-plugin-transform-react-remove-prop-types') isProduction && [require('babel-plugin-transform-react-remove-prop-types'), {
removeImport: true
}]
].filter(Boolean) ].filter(Boolean)
} }
} }
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment