4 ms·
It has always astonished me that platforms did not have first class, native "http client" support. Pretty much every project in the past 20 years has needed suc
by pbreit 1y ago
It has always astonished me that platforms did not have first class, native "http client" support. Pretty much every project in the past 20 years has needed such a thing.
Also, "fetch" is lousy naming considering most API calls are POST.
- rendall 1y agoThat's a category error. Fetch is just refers to making a request. POST is the method or the HTTP verb used when making the request. If you're really keen, you could roll your own const post = (url) => fetch(url, {method:"POST"})
- catlifeonmars 1y agoI read this as OP commenting on the double meaning of the category. In English, “fetch” is a synonym of “GET”, so it’s silly that “fetch” as a category is independent of the HTTP method
- rendall 1y agoThat makes sense.
- catlifeonmars 1y ago“Most” is doing a lot of heavy lifting here. I use plenty of APIs that are GET
- pbreit 1y agoI was thinking server-side where it's probably 90%+ POST. True, client-side a lot different (node the only player client-side, though).
- deleted 1y ago[deleted]
- tracker1 1y agoNode was created with first-class native http server and client support. Wrapper libraries can smooth out some rough edges with the underlying api as well as make server-side js (Node) look/work similar to client-side js (Browser).