A tuple type element list cannot be empty.

The solution for “A tuple type element list cannot be empty.” can be found here. The following code will assist you in solving the problem.

// bad
this.sService.getSome().then((value: []) => {
if (value.length > 0) {
console.log(value)
}
});

//fix
this.sService.getSome().then((value: [{}]) => {
if (value.length > 0) {
console.log(value)
}
});

Thank you for using DeclareCode; We hope you were able to resolve the issue.

More questions on [categories-list]

0
inline scripts encapsulated in