Ideally mapToPeriodScores should be done in the VM, and the ScoreBox component as a whole should accept ScoreBoxViewState instead of GameData. But if you don't want to refactor all of this right now we don't have to. For now, you could just make toPeriodScores a function on the GameData data class.
Originally posted by @zachseidner1 in #83 (comment)
Ideally
mapToPeriodScoresshould be done in the VM, and theScoreBoxcomponent as a whole should acceptScoreBoxViewStateinstead ofGameData. But if you don't want to refactor all of this right now we don't have to. For now, you could just maketoPeriodScoresa function on theGameDatadata class.Originally posted by @zachseidner1 in #83 (comment)