Sha256: c994cc2b63851c4d0da3adf99ddbe4a868a31fca381c26b1f10bc115f6212863

Contents?: true

Size: 295 Bytes

Versions: 3

Compression:

Stored size: 295 Bytes

Contents

# frozen_string_literal: true

module Phlex::Generators
	class ViewGenerator < ::Rails::Generators::NamedBase
		source_root File.expand_path("templates", __dir__)

		def create_view
			@path = File.join("app/views", class_path, "#{file_name}.rb")
			template "view.rb.erb", @path
		end
	end
end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
phlex-rails-2.0.0.rc1 lib/generators/phlex/view/view_generator.rb
phlex-rails-2.0.0.beta2 lib/generators/phlex/view/view_generator.rb
phlex-rails-2.0.0.beta1 lib/generators/phlex/view/view_generator.rb