This is a bit of a personal take, so feel free to reject if you disagree.
It took me "a while" to understand that events was a Dictionary when reading events.forEach { ... $0.key ... }. I think explicitly calling the parameter key, value makes for easier to read code.
Incidentally, key, value is the approach used elsewhere in the same file, so this also makes the code consistent.
This is a bit of a personal take, so feel free to reject if you disagree.
It took me "a while" to understand that
events
was a Dictionary when readingevents.forEach { ... $0.key ... }
. I think explicitly calling the parameterkey, value
makes for easier to read code.Incidentally,
key, value
is the approach used elsewhere in the same file, so this also makes the code consistent.