I have a LWC on a tab and when I open on a console app the title stuck on "Loading..". The workspaceAPI is the alternative, but it don't work on LWC. How to handle it? It's that any way to deal with? Without wrapping the LWC on aura?
1 Answer
I have achieved this by following below architecture:-
So basically, You don't need to wrap lwc in aura. You place them individually on the page. Make use of lightning message channel to communicate between them. Whenever you need to make workspaceapi call, fire the lightning messsage which will be listened by aura and fire workspace api.
You can check the working demo here:- https://videopress.com/v/oDmp34Qa
Follow this blog to get the working code:- https://salesforcediaries.com/2021/04/10/salesforce-console-apis-in-lightning-web-component/