I have created a LWC which is called from quick action.
The component has multiple wire methods that retrieves data from the record (field values, picklist values and so on) once the component is called.
I also have a property (isLoaded) which is initialize to true in the beginning, and responsible to show/hide the spinner in the UI.
Is there any why to mark this property to FALSE once ALL the wire methods completed and the data is fully loaded ?
This is my js example file:
isLoaded = true;
@wire (someMethod) wireMethod ({ error, data }){
if(data) ...
else if(error) ...
}
@wire (someMethod) wireMethod ({ error, data }){
if(data) ...
else if(error) ...
}
@wire (someMethod) wireMethod ({ error, data }){
if(data) ...
else if(error) ...
}
@wire (someMethod) wireMethod ({ error, data }){
if(data) ...
else if(error) ...
}
@wire (someMethod) wireMethod ({ error, data }){
if(data) ...
else if(error) ...
}
@wire (someMethod) wireMethod ({ error, data }){
if(data) ...
else if(error) ...
}
Thanks !