Sha256: ff17c1fe2dc4c3a0a41efb8a08d557865fbf9074d9f8aeeb0ce00a3cd1f20243
Contents?: true
Size: 698 Bytes
Versions: 1
Compression:
Stored size: 698 Bytes
Contents
require 'generators/ember/generator_helpers' module Ember module Generators class ViewGenerator < ::Rails::Generators::NamedBase include Ember::Generators::GeneratorHelpers source_root File.expand_path("../../templates", __FILE__) desc "Creates a new Ember.js view and associated template." class_option :without_template, :type => :boolean, :default => false, :desc => "Create template for this view" def create_view_files file_path = File.join(app_path, 'views', class_path, "#{file_name}.es6") template "view.es6", file_path invoke('ember:template', [ name ], options) unless options[:without_template] end end end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
ember-appkit-rails-0.5.0 | lib/generators/ember/view_generator.rb |