https://allaboutcoding.ghinda.com/how-to-create-value-objects-in-ruby-the-idiomatic-way

Creating Ruby Value Objects: The Idiomatic way

この海外記事ではRubyでValue Objectを作成する現代的な方法を紹介しています。

Value Objectは型と値で比較可能で、不変なオブジェクトです。

Ruby 3.2以降ではDataクラスを使用するのが一般的です。

Reply to this note

Please Login to reply.

Discussion

No replies yet.