React Pattern
Asynchronous request status
Use an explicit status to represent idle, loading, error or success. Empty data is a success case.
Formal Syntax & Structure
react syntaxreact
{status: "success", items: []}Working Example
Example Snippetreact
result.status === "loading"