Thank you, thank you thank you for bringing this up. I love elixir and all the people pushing the technology forward. It’s one of the greatest technologies since sliced bread… but I felt really stranded with this - Throw me off the side of the cliff and see if I can find my parachute.
I was excitedly looking forward to completing the exercise - so I hurriedly clicked the link to learn about this “live_patch” business. And boy - did I find that I had NO idea how to use what it was talking about. The LiveView help was not helpful for people learning LiveView - but only for those that already know LiveView and need a reminder.
I was disappointed “Sophie or Bruce” that you sent me to the den of Lions. You could have at least ended the link with a “Buwahahaha Buhahaha” as a warning that I was going to run into a steel wall at 100 miles an hour.
Then I search the internet - looking for an example. Because I knew that Bruce-or-Sophie was going to say - well, did you Google it (Google is everyone’s escape hatch) - I didn’t want to be on the wrong side - so I made sure that I went to as many places that Google sent me.
NOTHING - there were a few places with lip-service on the topic of live_patch.
I finally come across a discussion where José Valim gives a little bit better explanation of what live_patch does in comparison to it’s sibling alternative functions such as live_redirect, live_push etc.
But, still - NO examples of how a button or even a simple link plays a role in restarting a simple “You’re wrong” game.
Frustrated ?? - well … not overly - I still have sympathy for people that make hard things.
So, after going thru all those links starting from the book - I still don’t even know “What” get’s patched with “what.”
The instructions said - make a button to restart the game. We have barely even displayed our first screen - and now I’m asked to chase down ghost instructions.
C’mon Sophie and Bruce - Show some love.
What’s the answer?
Grumpy ol’ man
“Shame on me.” I thought. I had surely forgotten to look at the source code that came with the book. I didn’t think of this until I wrote my long manifesto above.
I downloaded the code - opened the whole glob in Visual Studio - and searched the whole thing for “live_patch”
There were several hits. However, - none related directly to the resetting the game. I peeked at the other implementations - of course they didn’t make sense to me because I don’t have enough context to which they apply.
So, I would like to make a recommendation to the authors.
I know it’s hard writing a book and a good one. But, it would be extremely helpful to the learner - if you would put the solutions in your code.
at least state - “We are going to cover this topic thoroughly in a later chapter. We promise not to leave you hanging.”
Ok, back to irritating my wife with the “The Little Elixir & OTP Guidebook” audio book.