Why JSON::Serializable uses @[JSON::Field], not @[JSON::Property]?

Probably because that’s just what the person that implemented the feature picked and no one had a better name when it was in review.

I think ideally there would be a common set of annotations that every format can use, versus every format requiring its own annotation.

I restarted a discussion about it Possible to serializer/deserialize and object like Ruby marshaling? - #15 by Blacksmoke16.

I also am in the process of refactoring my serialization shard to take this approach. CrSerializer - github.com/Blacksmoke16/CrSerializer. Currently it only supports JSON, but adding YAML/other formats is doable without having to redefine the common logic again and again.

1 Like