ES module support for check-es-compat
Its parserOptions doesn't include sourceType: 'module', and top-level await can only be used in ES modules.
Parsing error: Unexpected token Promise
I didn't check the tool before releasing v3.0.0, despite it being on the checklist in contributing.md
There are probably some things on the other hand, that are not allowed in sourceType=module.
Needs thinking.
Quite niche issue probably. Fix when doing next batch of work.
ES2020 import.meta and export * as have the same problem, nobody complained so far...
Tool needs to be told what the sourceType is, so needs a command line arg.
Even import/export statements don't work.
Would love to see this! We'd like to use this package to check our final frontend build, and most frontend builds these days are ESM (including ours)