JSONCodable icon indicating copy to clipboard operation
JSONCodable copied to clipboard

[WIP] Refactor to remove duplication

Open lightsprint09 opened this issue 9 years ago • 1 comments

This trys to reduce the duplication of JSONCodable. It is still work in progress. But I would love to hear a few opinions

  • Adds more small tests. When one tests fails it will be clear what causes the error.
  • Reuses more code, which could make maintaining more easy.

lightsprint09 avatar Jan 06 '17 10:01 lightsprint09

If you can get rid of duplication within the decode methods and get the tests working that would be great! Currently we are using multiple functions as a work around for the different ways the generic type could be returned, but if you can reuse some of the duplication that could be a nice refactoring win.

More tests are always great too 😄

Nadohs avatar Jan 15 '17 00:01 Nadohs