lightning/stateManagerRelatedListInfo

This state manager gets the metadata for a RelatedList.

Syntax 

Related list details depend on the parent object developer (API) name, related list ID, and optionally the record type.

1import { LightningElement } from 'lwc';
2import smRelatedListInfo from "lightning/stateManagerRelatedListInfo";
3
4export default class Example extends LightningElement {
5
6  const myRelatedListInfo = smRelatedListInfo({
7    parentObjectApiName: string,
8    relatedListId: string,
9    recordTypeId?: string // optional
10  });
11}

Configuration Functions 

setConfig()

Provide the entire configuration as an object. This function is equivalent to the factory function when you create the state manager.

setParentObjectApiName()

Set the parent object API (developer) name.

setRelatedListId()

Set the API name of a related list object, such as Contacts, Opportunities, or Cases.

setRecordTypeId()

Set the ID of the parent record type. If not provided, the default record type is used.

State Manager Properties 

status

The current status of the state manager. See status for details.

data

When status is "loaded", a Related List Info.

error

When status is "error", this property contains details. See error for details.

See Also