How to avoid loading notifications bundle for web build?


I am using expo and react native web. I have integrated FCM for notifications for web but expo also loads a notifications bundle which I do not want.

The issue is when the notification is received in the browser and message is clicked, the app gets the focus but crashes saying “TypeError: _emitter is undefined”. This is on this line in src/Notifications/Notifications.ts:40

_emitter.emit('notification', notification);

So, it seems expo tries to use its Notifications module. Can I remove that for web build?