Sha256: 52a1c31cd936188dbb3fe596e00dab38937543c376de6533f2338f989c46d8fc
Contents?: true
Size: 650 Bytes
Versions: 294
Compression:
Stored size: 650 Bytes
Contents
# frozen_string_literal: true require "active_support/concern" module Ariadne # :nodoc: module Audited # DSL to register when a component has passed an accessibility audit. # # Example: # # class MyComponent < ViewComponent::Base # include Ariadne::Audited::Dsl # audited_at 'YYYY-MM-DD' # end module Dsl extend ActiveSupport::Concern included do class_attribute :audit_date, instance_writer: false end class_methods do def audited_at(date = nil) return audit_date if date.nil? self.audit_date = date end end end end end
Version data entries
294 entries across 294 versions & 1 rubygems