Skip to content

Comments

refactor: replace default imports to named imports in mui component imports#380

Open
KyryloSWAN wants to merge 1 commit intostackworx:mainfrom
KyryloSWAN:fix-es6-import-errors
Open

refactor: replace default imports to named imports in mui component imports#380
KyryloSWAN wants to merge 1 commit intostackworx:mainfrom
KyryloSWAN:fix-es6-import-errors

Conversation

@KyryloSWAN
Copy link

The PR resolves errors with default imports like following:

⨯ Error [ERR_UNSUPPORTED_DIR_IMPORT]: Directory import '/.../node_modules/@mui/material/RadioGroup' is not supported resolving ES modules imported from /.../node_modules/formik-mui/dist/RadioGroup.js
Did you mean to import "@mui/material/node/RadioGroup/index.js"?
    at finalizeResolution (node:internal/modules/esm/resolve:259:11)
    at moduleResolve (node:internal/modules/esm/resolve:933:10)
    at defaultResolve (node:internal/modules/esm/resolve:1169:11)
    at ModuleLoader.defaultResolve (node:internal/modules/esm/loader:542:12)
    at ModuleLoader.resolve (node:internal/modules/esm/loader:510:25)
    at ModuleLoader.getModuleJob (node:internal/modules/esm/loader:239:38)
    at ModuleWrap.<anonymous> (node:internal/modules/esm/module_job:96:40)
    at link (node:internal/modules/esm/module_job:95:36) {
  code: 'ERR_UNSUPPORTED_DIR_IMPORT',
  url: 'file:///.../node_modules/@mui/material/RadioGroup',
  page: '/'
}

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant