Sha256: 730a8bbf0f9e9216857d633483d9662d7a816208e969469b9e88e6a8917fa9ed

Contents?: true

Size: 533 Bytes

Versions: 1

Compression:

Stored size: 533 Bytes

Contents

# frozen_string_literal: true

require 'rails/generators/erb/scaffold/scaffold_generator'
require 'generators/rails/base'

module Erb
  module Generators
    class ScaffoldGenerator
      include Rails::Base

      def generate_locale_file
        invoke('locale:view', [name]) if configuration.autoload_view_generator_locale
      end

      def generate_test_file
        framework = configuration.test_framework

        return if framework.nil?
        invoke("#{framework}:view", [name]) rescue nil
      end

    end
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
active_generator-5.0.0 lib/generators/rails/scaffold_generator.rb