-
Notifications
You must be signed in to change notification settings - Fork 1.7k
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
Error: Cannot resolve type entity i4.FocusTrapModule to symbol #6662
Comments
Hi @vignesh-s could you please provide plunker sample for better verification in the meantime what have you tried to add |
Yes, I am having |
I'm facing the same issue, and I created a repository that reproduces the issue for me. You can find it here: https://github.com/evil-o/ngx-bootstrap-6662-repro. The repository should be minimal, I created an Angular app with ng new (npm start works) and added an import of ngx-bootstrap (npm start shows the error in the original bug report). |
Thanks, that helps a lot! |
Replying for you @vignesh-s , @evil-o In my situation error because "ngx-bootstrap/focus-trap"
My environment is Windows 11 Pro and use NVM for manage version of node . How i Fix
I think import route are not work because if i try to click link ("ngx-bootstrap/focus-trap" ) they will route to path ("ngx-bootstrap/focus-trap/fesm2022/ngx-bootstrap-modal.mjs") and broken PS. if you have many people in project i will recommend create script for replace and set it in postinstall at package.json between wait fix patch CC. @lexasq my info can help you for clear it ? |
@vignesh-s @evil-o @PShonda thank you all on the intel. So far I think I found the issue, could you please try it as well. In your tsconfig.json Does work on @evil-o sample. I also found your solution as well @PShonda , unfortunatelly this is definitely not a lasting one. |
@lexasq I'm worried too. Thank you very much for the suggestion. |
@lexasq , that actually resolves the issue for me, both in the minimal sample and my actual application! I assume this is a workaround? Bundler module resolution, in my opinion is more appropriate for an angular application, and it's also the default setting that the Angular CLI generates. In any case, for now, this fixes my issue, so thanks for the quick response! |
@lexasq Just BTW - this actually prevents using some libraries without nasty workarounds. See for example benjamine/jsondiffpatch#356 (comment) |
@slubowsky you are right, it's very unfortunate, but whole library builds as node now, so that is the best solution we could offer right now. We're restarting our opensource contributions, and chances are we'll get to this issue as well. |
I changed all FocusTrapModule imports to ngx-bootstrap/focus-trap.module but still facing this issue. |
@salartaimoor10 this is the answer |
@lexasq Thankyou, now it is working |
importing
ModalModule.forRoot()
gives the below error on starting the server in angular 18Versions of ngx-bootstrap, Angular, and Bootstrap:
"@angular/core": "^18.0.6",
"bootstrap": "^5.3.3",
"ngx-bootstrap": "^18.0.0",
Build system: Angular CLI
Expected behavior
Server should start without any error
The text was updated successfully, but these errors were encountered: