Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Error: Cannot resolve type entity i10.BidiModule to symbol while building angular Lib project Angular 13

I am facing Error: Cannot resolve type entity i10.BidiModule to symbol while building angular Lib project. There are 2 other lib projects which are building fine. This new lib project works well without flex layout and material. But when I use flex layout or material in this project I got below error. I have search a lot. There is solution like including "preserveSymlinks": true in tsconfig.lib.json. Unfortunately its not working for me. Any help on this will be welcome.

enter image description here

like image 739
Uali Avatar asked Feb 17 '26 00:02

Uali


2 Answers

I ran into this very same issue today. I had a library project for Angular 13 and after adding the @angular/flex-layout as a dependency, I could no longer build the library with the exact same error as you.

I managed to fix the problem by adding @angular/cdk as a dependency to my library. I found this information on the flex layout github page, where they install both of these libraries in the "Getting Started" section.

I did not change any other configuration files.

npm install @angular/cdk --save

like image 113
Minop Avatar answered Feb 18 '26 14:02

Minop


My team ran into this when adding SyncFusion modules to some of our shared projects, which we have structured in a monorepo. After much head scratching and failing with the @angular/cdk & preserveSymlinks solutions out there, I figured out a tweak to my tsconfig.json that made it work for me:

    "paths": {
        "@syncfusion/*": [
            "./node_modules/@syncfusion/*"
        ],
    },

For whatever reason, Typescript sometimes gets confused about where to find certain packages in our environment. Our tsconfig paths section actually has a grab-bag of items in there to smooth things out. Sigh.

like image 28
Matthew Marichiba Avatar answered Feb 18 '26 14:02

Matthew Marichiba



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!