Closed BerkliumBirb closed 3 months ago
const value = await filter.loading
Interesting idea!
Also, next
has await loadValue()
and ensureLoading
(for tests)
Adding await filter.loading
is hard because of how Promise work and that we use lazy stores.
Please use value = await loadValue(store)
it does exactly what do you need.
In next version
{ isLoading: true }
is typed separately from{ isLoading: false, isEmpty: boolean, list: ... }
. That makes TypeScript freak out when you write something like this:It would be easier to write this instead: