holen icon indicating copy to clipboard operation
holen copied to clipboard

Declarative fetch for React

Results 13 holen issues
Sort by recently updated
recently updated
newest added

To prepare for async rendering coming in a not too distant version of React, the following lines of the use of the lifecycle method `componetWillReceiveProps` should be removed. Here is...

Many enterprisey APIs don't respect the `Accept` header, so even if you specify JSON you may get something else entirely back. i.e.; old Java/Apache web servers frequently return text stack...

Holen's default `type` is `"json"`, which works for most API endpoints. However, a very common feature of APIs is the useful `204 No Content` response. This is typically returned from...

help wanted

React does not permit you to call `setState` within `render`. However, Holen allows you to do this via code such as: ```jsx fetch()} /> ``` Clearly, nobody would write code...

Holen is susceptible to race condition bugs. One situation where it is more noticeable is when network conditions aren't great, or when you have one slow endpoint and one fast...

`fetch()` accepts a URL string as `init` as well as a [Request](https://developer.mozilla.org/en-US/docs/Web/API/Request) object. Holen accepts the URL string via the `url` prop. It could accept an instance of Request as...

The body could likely be limited to just strings and instanceof Blob, BufferSource, FormData, and URLSearchParams. If you're :+1: I'll open a PR. Thanks! [Source](https://developer.mozilla.org/en-US/docs/Web/API/WindowOrWorkerGlobalScope/fetch)

I think that this value chart maps out a more useful default for the `lazy` prop: | Method | Default value | | ------------------------ | ------------- | | GET, HEAD,...

Fetch will soon support [aborting](https://developers.google.com/web/updates/2017/09/abortable-fetch) in evergreen browsers (and the popular GitHub polyfill [will as well](https://github.com/github/fetch/pull/592)). Given that this component can refetch after it is mounted, I don't think that...