Skip to content

Prerelease v22.2.0-sam.3

Pre-release
Pre-release

Choose a tag to compare

@dolittle-build dolittle-build released this 07 Feb 12:59
cfff501

Summary

Implements the new structures of Projection registration copy to MongoDB conversion arguments. A few notes:

  • Renaming is not implemented, I don't see how that would be useful in JS/TS. And it would require work to extend the MongoDB deserialiser somehow.
  • @convertToMongoDB decorators on nested types are not detected. In general nested types on Projections don't work that well, so I'll leave that for a bigger effort later.
  • If you have properties with . in the name, the .WithConversion('property.name', ...) will generate wrong conversion structures. I don't see a nice way to deal with this alongside the fancy TS magic to get compiler warnings on those strings.

I feel like there is time to add a few specs on some of these things. I'll leave the PR for a little longer. I have tested it with the sam.6 release of the Runtime, and it is pretty cool!