Error Code Portal
Node.jsNode.jsError code

ERR_UNSUPPORTED_DIR_IMPORT

unsupported dir import

Code ERR_UNSUPPORTED_DIR_IMPORT · An issue reported by Node.js.

import a directory URL is unsupported. Instead, self-reference a package using its name and define a custom subpath in the "exports" field of the package.json file.

Troubleshooting and diagnostic links

First check that the document's product, version, and environment match your situation.