Sha256: 9f9cb17d54ed57ffcdbffb86bf368065a27d420caab54f2d19c681dcac34127d

Contents?: true

Size: 259 Bytes

Versions: 5

Compression:

Stored size: 259 Bytes

Contents

# frozen_string_literal: true

class <%= class_name %> < ::ApplicationComponent
  # Props that your component accepts
  prop :description, default: -> { 'Default Description' }

  after_initialize do
    # some initialization
    @time = ::Time.now
  end
end

Version data entries

5 entries across 5 versions & 1 rubygems

Version Path
amber_component-1.2.0 lib/generators/templates/component.rb.erb
amber_component-1.1.1 lib/generators/templates/component.rb.erb
amber_component-1.1.0 lib/generators/templates/component.rb.erb
amber_component-1.0.0 lib/generators/templates/component.rb.erb
amber_component-0.0.5 lib/generators/templates/component.rb.erb