function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
sunny sengar 17sunny sengar 17 

Hi @all, I am new in LWC, And want to convert LC to LWC. Anyone can help

<aura:component implements="force:appHostable,flexipage:availableForAllPageTypes,flexipage:availableForRecordHome,force:hasRecordId,forceCommunity:availableForAllPageTypes,force:lightningQuickAction" access="global" >
     <aura:handler event="force:showToast" action="{!c.handleToastEvent}"/>
</aura:component>



({
    handleToastEvent: function(component, event, helper) {
        var toastMessageParams = event.getParams();
        var message = toastMessageParams.message;
        if(message.includes('saved')) {
            setTimeout(function(){ location.reload();}, 1000);
        }
    }
})
ravi soniravi soni
hi sunny,
force:showToast this is aura standard event it works when any notifaction excute.
but its not work in Lwc.
there is no chance.
don't forget to mark it as best answer.
Thank you