'Can I replace the functionality of Platform Event in LWC?

I have a lwc that works with Event Platforms, but event limits are exceeded and I can't reduce them. Is there any functionality or method that can refresh my component in real time without platform events?.



Solution 1:[1]

Sometimes money is an answer, consider buying an addon to increase the limit.

If it's 1 component talking to another component on same page and telling it to rerender - look into Lightning Message Service. It's not perfect (couldn't get it to work on mobile) but could be good enough for you.

When all else fails - consider handmade polling. What if you use window.setTimeout() and call apex function say every 5 seconds to check if stuff changed. It'll be network-intensive but could be good enough to fetch fresh data.

Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source
Solution 1 eyescream