Sha256: 17659f8b23e5a44bf64b3cd79f6cb8ab48bd3009111babbb7fe94de926fc7ab5

Contents?: true

Size: 513 Bytes

Versions: 6

Compression:

Stored size: 513 Bytes

Contents

require "slim"
require "dry-view"
require "<%= config[:underscored_app_name] %>/container"
require "<%= config[:underscored_app_name] %>/page"

module <%= config[:camel_cased_app_name] %>
  Container.register "page", Page.new

  class View < Dry::View::Layout
    setting :root, Container.root.join("web/templates")
    setting :scope, Container["page"]
    setting :formats, {html: :slim}
    setting :name, "application"

    def locals(options)
      super.merge(options[:scope].view_locals)
    end
  end
end

Version data entries

6 entries across 6 versions & 1 rubygems

Version Path
dry-web-roda-0.5.1 lib/dry/web/roda/skeletons/app/system/__underscored_app_name__/view.rb.tt
dry-web-roda-0.5.0 lib/dry/web/roda/skeletons/app/system/__underscored_app_name__/view.rb.tt
dry-web-roda-0.4.0 lib/dry/web/roda/skeletons/app/component/__underscored_app_name__/view.rb.tt
dry-web-roda-0.3.0 lib/dry/web/roda/skeletons/app/component/__underscored_app_name__/view.rb.tt
dry-web-roda-0.2.3 lib/dry/web/roda/skeletons/app/component/__underscored_app_name__/view.rb.tt
dry-web-roda-0.2.2 lib/dry/web/roda/skeletons/app/component/__underscored_app_name__/view.rb.tt