mirror of
https://github.com/hanzoai/babel.git
synced 2026-09-24 16:56:45 +00:00
Instead of using `convert-source-map`'s `removeComments` method before parsing the file, we can first parse the file with `@babel/parser` and then analyze the comments. This is needed because it is not possible to reliabily detect comments in JavaScript without fully parsing the file: https://github.com/thlorenz/convert-source-map/issues/63