Wow, a new extension for ES modules? That seems really unfortunate.<p>Why can&#x27;t node parse a file to detect if it&#x27;s a module? The presence of a top-level import or export means it&#x27;s a module. If it&#x27;s not, then the parsed file can be kept if the file is also in strict mode. If it&#x27;s sloppy, it&#x27;ll have to be re-parsed. Seems like a small penalty if the goal is to enable migration.<p>Also, why worry about ES modules importing Common JS? Just disallow that and let projects migrate to ES modules bottom-up. Then you don&#x27;t have to worry about executing a Common JS module to determine what its exports are or circular dependency problems.