diff --git a/packages/babel-parser/typings/babel-parser.d.ts b/packages/babel-parser/typings/babel-parser.d.ts index d53210217a..76f0f327e0 100644 --- a/packages/babel-parser/typings/babel-parser.d.ts +++ b/packages/babel-parser/typings/babel-parser.d.ts @@ -48,6 +48,13 @@ export interface ParserOptions { */ allowUndeclaredExports?: boolean; + /** + * By default, Babel always throws an error when it finds some invalid code. + * When this option is set to true, it will store the parsing error and + * try to continue parsing the invalid input file. + */ + errorRecovery?: boolean; + /** * Indicate the mode the code should be parsed in. * Can be one of "script", "module", or "unambiguous". Defaults to "script".