BackendTask.Http

Scenarios where BackendTask.Http is a good fit page

If you need data that is refreshed often you may want to do a traditional HTTP request with the elm/http package. The kinds of situations that are served well by static HTTP are with data that updates moderately frequently or infrequently (or never).

A common pattern is to trigger a new build when data changes. Many JAMstack services allow you to send a WebHook to your host (for example, Netlify is a good static file host that supports triggering builds with webhooks). So you may want to have your site rebuild everytime your calendar feed has an event added, or whenever a page or article is added or updated on a CMS service like Contentful.

In scenarios like this, you can serve data that is just as up-to-date as it would be using elm/http, but you get the performance gains of using BackendTask.Http.Requests as well as the simplicity and robustness that comes with it. Read more about these benefits in this article introducing BackendTask.Http requests and some concepts around it. ⇒ A is for API - Introducing Static HTTP Requests page

~

owner:dillonkearns BackendTask.Http search