tag:blogger.com,1999:blog-8643857899806162280.post4308475429461959432..comments2024-02-25T06:15:55.318-03:00Comments on Bug squash: Refactoring to functional ActionResults in FigmentMauricio Schefferhttp://www.blogger.com/profile/15247972578064164206noreply@blogger.comBlogger3125tag:blogger.com,1999:blog-8643857899806162280.post-44932952983416172192023-06-04T03:30:36.111-03:002023-06-04T03:30:36.111-03:00Great post, thank youGreat post, thank youIce Cream Recipeshttps://www.icecreamideas.com/ice-cream/homemade_vanilla_sprinkles_ice_cream_5488086618.shtmlnoreply@blogger.comtag:blogger.com,1999:blog-8643857899806162280.post-52551190010639151472011-06-28T15:11:22.415-03:002011-06-28T15:11:22.415-03:00@Ryan: yeah, I saw that somewhat similar was happe...@Ryan: yeah, I saw that somewhat similar was happening in Frank. However I don't need a writer or a state in Figment, since everything (Request AND Response) is in the ControllerContxt which itself is readonly. The reader is simply executed by passing the ControllerContext instance.<br />I still think a pure request -> response type is better, but I don't think it's possible with ASP.NET types, because ActionResult = ControllerContext -> unit , which means nothing but side-effects on ControllerContext, which in turn means having to mock Request, Response, etc, as all ASP.NET apps have to do when testing at that level. I may write a post about testing in Figment, comparing it to Frank.Mauricio Schefferhttps://www.blogger.com/profile/15247972578064164206noreply@blogger.comtag:blogger.com,1999:blog-8643857899806162280.post-89644077135194199552011-06-28T12:34:26.481-03:002011-06-28T12:34:26.481-03:00Beautiful. I started down this path originally wit...Beautiful. I started down this path originally with Frank. The problem I ran into was trying to tie the reader and writer monads together, so I eventually opted for the state monad, which is now also gone. I think this works well for you, though, as you have picked a specific platform. By the way, do you plan to do the same on the write side? I'm curious to see how you handle either a monad transform or executing the reader in your app directly. Cheers!Ryanhttps://www.blogger.com/profile/10643337675808040478noreply@blogger.com