Mitigating Optimization Bailouts in Angular with Sisense SDK: Handling CommonJS/AMD Dependencies
I’m experiencing longer build times after integrating the Sisense Angular SDK into my project. Profiling suggests that CommonJS/AMD dependencies in the SDK are triggering optimization bailouts during the build process.
Has anyone encountered similar issues with the Sisense SDK? I’m looking for strategies to reduce these bailouts or optimize the integration to better fit Angular’s ES module requirements. Any advice on how to improve build performance while using this SDK would be greatly appreciated!
herajapakse
6 comments
tuan
herajapakse and IsaacBlanco yesterday we released CSDK 1.18.0 that contains a fix for this. Please give it a try and let us know if it resolves your issue.
IsaacBlanco
Thanks for raising this issue herajapakse , I'm having the same problem currently with my Angular app
tuan
Thanks herajapakse for additional details. We are reviewing a fix to replace `lodash` and `object-hash` with alternatives in ESM format. It will be ready in CSDK v1.18.0 to be released early next week.
herajapakse
OPI get this warnings along with a increase in build time when I inject the SisenseContextConfig in to the application
Sisense User
herajapakse could you share more information? does profiling show what specific CommonJS/AMD dependencies are being pulled in? The @sisense/sdk-ui-angular package is already bundled as ESM, so I'm curious if there's a downstream library we're importing as CJS.
DRay
Hello herajapakse.
Thank you for reaching out. I see this doesn't have an answer yet, so I am reaching out internally.