I’m aware that I can name a file with
.mjs or set
"type": "module" in package.json. I’m also aware of the
--input-type=module CLI parameter.
What I’m not understanding is, why isn’t there a way to pass a parameter flag to force module interpretation for the
.js file I specify? Was there a reason that
--input-type can only be used with string input and not to control module interpretation of a
I tried searching old issues to find this discussed but my searching failed me. I feel certain it must have been intentionally omitted, but I’m just trying to understand why?