Skip to content

Commit ccf5f64

Browse files
committed
Show more reading of current state
1 parent 7ce199e commit ccf5f64

1 file changed

Lines changed: 2 additions & 0 deletions

File tree

readme.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -38,11 +38,13 @@ function Loader({ url }) {
3838
}
3939

4040
const loader = start(Loader, { url: new URL("https://example.org/") });
41+
loader.value; // "idle"
4142

4243
loader.next("FETCH");
4344
loader.value; // "loading"
4445

4546
loader.promisedValue.then(response => {
4647
// Use response of fetch()
48+
loader.value; // "success"
4749
});
4850
```

0 commit comments

Comments
 (0)