Skip to content

Releases: MatheusRich/ez_attributes

v0.3.0

25 Oct 21:36
Compare
Choose a tag to compare

[0.3.0] - 2021-10-25

Changed

  • Allow configuring EzAttributes (PR #3)
class User
  extend EzAttributes.configure(getters: false)

  attributes :name, :age, email: 'guest@user.com'
end

User.new(name: 'Matz', age: 22).name
# NoMethodError (undefined method `name' for #<User:0x000055bac152f130>)
  • Replace Rubocop with StandardRB

v0.2.2

30 Apr 12:24
Compare
Choose a tag to compare

Changed

  • Fix shared state between class instances. (Commit 759abc7)

v0.2.1

20 Jan 17:34
Compare
Choose a tag to compare

Changed

  • Do not generate getter for attribute named class. This prevents overriding the Object#class method.

v0.2.0

20 Jan 00:50
Compare
Choose a tag to compare

Added

  • Allow using reserved words as attributes.
Class.new do
  extend EzAttributes

  # This would break in 0.1.0.
  # Now it works.
  attributes :class, :if
end

v0.1.0

25 Nov 00:37
Compare
Choose a tag to compare

Basic module to define class initializers with keyword args.