Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bug: Module ‘./icons/modules/classic/regular’ Not Found in Package Exports #20243

Closed
1 of 2 tasks
Julius-717 opened this issue Jun 6, 2024 · 3 comments
Closed
1 of 2 tasks
Labels
bug needs-triage This bug needs to be confirmed

Comments

@Julius-717
Copy link

Bug description

Hello,

everytime we try to compile we get a bunche of:
./src/app/app.module.ts:25:0-401 - Error: Module not found: Error: Package path ./icons/modules/classic/regular is not exported from package C:\Users\mobile\node_modules\@awesome.me\kit(see exports field in C:\Users\mobile\node_modules\@awesome.me\kit\package.json)
and
`Error: src/app/app.module.ts:48:8 - error TS2307: Cannot find module '@awesome.me/kit/icons/modules/classic/regular' or its corresponding type declarations.

48 } from "@awesome.me/kit/icons/modules/classic/regular"`

We always have to modify the node_module package.json from:
"./icons/classic/regular": { "types": "./icons/modules/classic/regular.d.ts", "import": "./icons/modules/classic/regular.mjs", "require": "./icons/modules/classic/regular.js", "default": "./icons/modules/classic/regular.js" },
to
"./icons/modules/classic/regular": { "types": "./icons/modules/classic/regular.d.ts", "import": "./icons/modules/classic/regular.mjs", "require": "./icons/modules/classic/regular.js", "default": "./icons/modules/classic/regular.js" },

When will the module package.json be fixed? Or is there a way we can fix that?
Thanks a lot

Font Awesome version

v6.0.0

Application and Operating System

Ionic/Capacitor native mobile app

Web bug report checklist

  • I have included a test case because my odds go way up that the team can fix this when I do
  • I have searched for existing issues and to the best of my knowledge this is not a duplicate
@Julius-717 Julius-717 added bug needs-triage This bug needs to be confirmed labels Jun 6, 2024
@robmadole
Copy link
Member

Hey there. Check out the docs here and let us know if you still have issues:

https://docs.fontawesome.com/web/dig-deeper/kit-package-api/#typescript

@Julius-717
Copy link
Author

I did and we still experienced the same issue

@robmadole
Copy link
Member

Make sure you remove "modules" from your import paths. Please double-check the syntax for that.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug needs-triage This bug needs to be confirmed
Projects
None yet
Development

No branches or pull requests

2 participants