3 ms·
I'm one of the unwashed masses that probably just doesn't see the Point, but I'm confused why claims like this are made. > the last API you'll ever need So li
by recursive 10y ago
I'm one of the unwashed masses that probably just doesn't see the Point, but I'm confused why claims like this are made.
> the last API you'll ever need
So like... if I wanted to make a post to twitter, I'm pretty sure I'd need another API.
- daneel 10y agoAPI in this case refers to it's original meaning, that is, the interface that is available on a specific "class" of objects. Here, the "class" of objects are mimicking haskell like typeclasses. The chart on the fantasy-land github page demonstrates the interfaces available on each typeclass. For instance, a Maybe is a functor, so it has the map interface. It's also a Monad so it has the chain interface. Unfortunately, API is a loaded term and I think the author doesn't do a good job differentiating from the common usage of the term.
- recursive 10y agoEven in that meaning, it still doesn't make sense. Say there was an abstracted twitter standard defined in an RFC, and a library was provided for interacting with it. There is no Twitter(tm), just implementations of the twitter RFC. Even then, I need to know what the names of the properties are that I have to provide to the fantasy-land-compliant-whatever. Being an expert in fantasy land doesn't tell me that "message" is the property that contains the body of the twitter-compliant message. I still need an api.
- cjhveal 10y agoA programatic interface can be exposed via functions over data structures, methods on objects, or HTTP requests against a server's endpoints, to name a few examples. I think the confusion here arises from a fairly common conflation of a web service with the interface used to interact with said service.
- recursive 10y agoIn that case, it seems like a fairly empty claim. Here's another "last API you'll ever need". value["functionName"](...[arguments]) value is the the thing you're operating on. functionName is the name of the thing you want to do. arguments are any other relevant values.