jaikamat / clubhouse-pos-importer

Monorepo for an LGS's inventory management system
1 stars 0 forks source link

Refactor out `Object.assign` #221

Closed jaikamat closed 3 years ago

jaikamat commented 3 years ago

Summary

Legacy versions of modeled context card objects were class instances with getter and setter (the old InventoryCard class) methods, which could not cleanly be destructured and failed TS compilation if we tried. Recently those get/set methods were refactored away, and this PR restores creating new objects using commonplace means of destructuring rather than using fancy (and buggy?) Object.assign tricks.