Skip to content

ERR_UNSUPPORTED_DIR_IMPORT when building a project #1326

@djohts

Description

@djohts
  • I have searched the Issues to see if this bug has already been reported
  • I have tested the latest version

Steps to reproduce

  1. Update to [email protected]
  2. Build the project via next build

Current behavior

[18:51:29.228]  ✓ Compiled successfully
[18:51:29.229]    Collecting page data ...
[18:51:29.548] unhandledRejection Error [ERR_UNSUPPORTED_DIR_IMPORT]: Directory import '/vercel/path0/node_modules/.pnpm/[email protected][email protected][email protected][email protected]/node_modules/flowbite-react/lib/esm/components/Accordion' is not supported resolving ES modules imported from /vercel/path0/node_modules/.pnpm/[email protected][email protected][email protected][email protected]/node_modules/flowbite-react/lib/esm/index.js
[18:51:29.548]     at finalizeResolution (node:internal/modules/esm/resolve:258:11)
[18:51:29.548]     at moduleResolve (node:internal/modules/esm/resolve:917:10)
[18:51:29.548]     at defaultResolve (node:internal/modules/esm/resolve:1130:11)
[18:51:29.548]     at ModuleLoader.defaultResolve (node:internal/modules/esm/loader:396:12)
[18:51:29.548]     at ModuleLoader.resolve (node:internal/modules/esm/loader:365:25)
[18:51:29.548]     at ModuleLoader.getModuleJob (node:internal/modules/esm/loader:240:38)
[18:51:29.548]     at ModuleWrap.<anonymous> (node:internal/modules/esm/module_job:85:39)
[18:51:29.548]     at link (node:internal/modules/esm/module_job:84:36) {
[18:51:29.548]   type: 'Error',
[18:51:29.548]   code: 'ERR_UNSUPPORTED_DIR_IMPORT',
[18:51:29.549]   url: 'file:///vercel/path0/node_modules/.pnpm/[email protected][email protected][email protected][email protected]/node_modules/flowbite-react/lib/esm/components/Accordion'
[18:51:29.549] }
[18:51:29.607]  ELIFECYCLE  Command failed with exit code 1.
[18:51:29.624] Error: Command "pnpm run build" exited with 1

Expected behavior

Build finishes successfully.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions