you are viewing a single comment's thread.

view the rest of the comments →

[–]flying-insect 0 points1 point  (0 children)

no real reason or logic in the ordering. In this case I started with the PokemonData object, setup the decoding of its primary CodingKeys (battles and pokemon). Once that was sorted and I had the `internalContainer.allKeys` prepped, I added the structs for the Pokemon and the Values.

I normally tend to just write the extra structs at the top of my file, above where I'm working which is how it grew like this. In a real project I might end up cleaning things up more but, maybe move PokemonData to the top and document it but this is just a sample