Ciao!
What are the stories behind your crafts? You know, this week I didn’t manage to publish my usual post on Friday. I actually sat down, brainstormed and wrote for a few hours. But I could not manage to collect the ideas under a compelling umbrella. It missed a beginning, a direction and an end. Then I realized I broke one of my rules: always start from a story.
But hey, in software it’s the same. Take the following two tickets as an example:
Which one do you think has the bigger potential for a piece of software that the user would find delightful, provide a better service to the customers of the bakery and generate more value to the business as a whole? You bet it’s the second!
You see? A story does not need dragons, explosions or bad puns. But it does make a huge difference on both sides of the counter. Also, it’s not that hard to get a story once you start looking for it. Just keep moving, even if it’s the wrong direction as I did. Sure, I didn’t publish on Friday but I got a story to share with you.
Yet more tricks from the production trenches. Both the strategies laid out in the post apply regardless of the frontend framework you use (it doesn’t have to be Elm).
Elm Tricks from Production–Adding Event Listeners to DOM Nodes that do not yet Exist - How to use setTimeout
and the DOM mutation observer API to attach callbacks to DOM nodes that do not yet exist.
Have you ever wondered what’s the secret at the core of a compiler? Join me for a five-minute tour of a tiny one.
PureScript/Haskell: Tiny Compiler - The trick in a compiler is to take a string and transform it into a data structure that can be easily manipulated.
# Create and check out a new branch # named <branchname> starting from # the commit at which the <stash> was # originally created and apply the # changes recorded in <stash>. # Useful when pop fails due to conflicts. git stash branch <branchname> [<stash>]
# Create a stash entry and return # its object name, without storing # it anywhere in the ref namespace. # Useful for scripts. git stash create
# Show the changes recorded in the second most # recent stash entry as a diff between the # stashed contents and the commit back when # the stash entry was first created. git stash show --patch 1
# Make more than one commit out of the # changes in the work tree but test each # change before committing. git add --patch git stash --keep-index # test and commit git stash pop
# Clean the working tree interactively by # recursively removing files and directories # that are not under version control, # starting from the current directory. git clean --interactive -d
# List branches which contain the specified # commit (HEAD if not specified). git branch --contains [<commit>]
When setting myself up for an experiment I’ve always thought of two strategies to keep track of it: sticking to a specific amount of input (e.g. read 30 minutes a day) or to a specific amount of output (e.g. read 52 books this year). This week I found another way to look at it.
CGP Grey suggests finding Your Theme and avoid specific goals. This looks promising!
This is the story of my week. What is yours? Hit reply and say hi.
I’m looking forward to hear from you.
Let’s connect.
Really.
Thanks for spending some time reading with me. Talk to you soon.
Yours truly,
Riccardo.