cofree-coffee / cofree-bot

A library for building bots compositionally.
41 stars 8 forks source link

Modify Inputs and Outputs Independently Using Optics #21

Open solomon-b opened 2 years ago

solomon-b commented 1 year ago

I can't remember the context for this. Is it something other then dimap? @masaeedu

masaeedu commented 1 year ago

I don't remember what this specific issue is about either, but assuming we have various subclasses of Profunctor implemented, and we do a little busywork to deal with the annoying historical presentational warts of profunctor optics in Haskell, we should be able to "focus" existing bots and servers by simply applying profunctor optics to them.