isographlabs / isograph

The UI framework for teams that move fast — without breaking things.
MIT License
245 stars 16 forks source link

API for reading fragment reference that returns union and doesn't suspend #272

Open rbalicki2 opened 2 days ago

rbalicki2 commented 2 days ago

You should be able to call getStateOfFragmentReference(fragmentRef) and that should return { kind: 'Pending' } | { kind: 'Data', dat: T }

It should be pending if it would suspend. This may not equal that a network request is in flight, it might suspend due to other data changing.