We can do it by tokenizing escaped keywords as normal identifiers, so that they won't be accidentally used as real keywords.
@babel/parser
A JavaScript parser
See our website @babel/parser for more information or the issues associated with this package.
Install
Using npm:
npm install --save-dev @babel/parser
or using yarn:
yarn add @babel/parser --dev