Skip to main content

Demo Usage APIs

Data sources

Request a data source

// Request userList (defined in the data source panel)

this.dataSourceMap['userList']
.load({
data: {},
})
.then((res) => {})
.catch((error) => {});

Read data source values

const { userList } = this.state;

Update data source values manually

// Read value defined in the data source panel
const { user } = this.state;

// Update state
this.setState({
user: {},
});