We have an angular application with version 20 and when we are converting our repos to native federated mfe with native federation V 20,We are facing below issue with object-sizeof library as it only supports node not browser,While federation we are getting below errors.
main.ts:6 Error: Dynamic require of "buffer/" is not supported
at chunk-4H3CUAZM.js:31:11
at node_modules/object-sizeof/indexv2.js (byte_size.js:21:1)
at __require2 (chunk-4H3CUAZM.js:49:52)
at indexv2.js:138:1
We are using it as import sizeof from 'object-sizeof';
to have this issue reproducible, we just need to import object-sizeof and use it in the code.
Below github code: https://github.com/JijiyaT/angular-nativefederation
Is there any way i can use this lib for ES Module.Any suggestions/feedback is helpful.