4

I have a requirement to send messages from LWC component to an Aura component. The component exist on the page independently, i.e LWC is not embedded in an aura component. The components are in a lightning community and the aura component is a part of page header and lwc component is placed in one of the detail page.

Is it possible through pubsub?

Note : I'm aware that the lightning message service is going to come in future release.

1 Answer 1

3

Lightning Message Service in GA seems to be a promising feature for this approach.

However, if you want to roll your own then pubsub repo has a simple library. Note that pubsub library falls under no support agreement with Salesforce.

2
  • 2
    All the code links in this answer are now dead. Feb 3, 2021 at 16:03
  • 1
    @RobBaillie Fixed the repo link! Jun 7, 2021 at 18:42

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .