Fork me on GitHub
#gratitude
<
2023-08-22
>
emilaasa17:08:20

Thanks to @ericnormand for sharing your insights in the form of a nice podcast, and all your things at http://purelyfunctional.tv I listened to several of your https://ericnormand.me/podcast/executable-specification-lens and gave (roughly) the method you outlined a shot when doing some design for a small program at work today. I kept it very simple with basically creating several functions that looks something like this:

;; TODO @aasa maybe we already have the token before this function is called,
;; and it should be a parameter?
(defn login []
  (println "User wants to login.")
  (if (local-token!)
    (println "You are already logged in.")
    (start-login-flow)))
It really helped with outputting a good overview of what I think the program should do, and I'll try to keep using this throughout this project to try it out some more. I thought it was a great method to quickly get a more tangible feel of the problem, compared to only doing sketches or sequence diagrams which are my go-to at the stage of design I'm in at the moment. In particular, by pushing the IO implementations forward it was a very fast way to get an overview of the problem and my solution ideas. So thanks for that, and rock on! 😉

❤️ 3
gratitude 6
👍 2