Sha256: a58928bdb3488c95c9487155ae9c47470193d3645cc1ece0e05db60b8eaa12f9
Contents?: true
Size: 439 Bytes
Versions: 1
Compression:
Stored size: 439 Bytes
Contents
class PresenterGenerator < Rails::Generators::Base source_root File.expand_path('../templates', __FILE__) argument :presenter_name, type: :string def generate name = presenter_name.singularize create_file "app/presenters/#{name.underscore}.rb", <<-FILE class #{name.classify} < UberPresenter::Base # def posts # # ... # end # Кэширование результатов # memoist :method end FILE end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
uber_presenter-0.1.0 | lib/generators/presenter/presenter_generator.rb |