Add sourceType as a new mandatory option

Summary:
The `sourceType` option is a new mandatory option for Babel which determines whether to parse the file with the module or script goal. The value "disambiguous" determines this state by parsing.

See https://github.com/babel/babel/pull/7417

Reviewed By: mjesun

Differential Revision: D7685610

fbshipit-source-id: 3958c5ad396592bb1d790e2df4ce315737421a2f
This commit is contained in:
Peter van der Zee 2018-04-19 09:53:11 -07:00 committed by Facebook Github Bot
parent 8642356367
commit 3aa453d975
1 changed files with 1 additions and 0 deletions

View File

@ -53,6 +53,7 @@ module.exports = {
platform: '',
projectRoot: '',
retainLines: true,
sourceType: 'unambiguous', // b7 required. detects module vs script mode
},
src,
plugins: [