require: - rubocop-graphql - rubocop-performance - rubocop-rails - rubocop-rspec AllCops: Exclude: - bin/* - db/schema.rb - vendor/bundle/**/* NewCops: enable TargetRubyVersion: 3.1.2 # Layout Layout/ClassStructure: Categories: associations: - belongs_to - has_one - has_many - has_and_belongs_to_many attributes: - attr_accessor - attr_reader - attr_writer - attr_accessible - attribute callbacks: - before_validation - after_validation - before_save - around_save - before_create - around_create - after_create - after_save - after_commit macros: - accepts_nested_attributes_for - has_secure_token - serialize module_inclusion: - include - prepend - extend scopes: - default_scope - scope validations: - validate - validates - validates_each ExpectedOrder: - module_inclusion - scopes - public_constants - public_attributes - enum - associations - validations - delegate - callbacks - macros - initializer - public_methods - public_class_methods - protected_methods - private_constants - private_attributes - private_methods Enabled: true Layout/EmptyLinesAroundClassBody: Enabled: true EnforcedStyle: empty_lines Layout/EmptyLinesAroundModuleBody: Enabled: true EnforcedStyle: empty_lines_except_namespace Layout/IndentationConsistency: Enabled: true EnforcedStyle: indented_internal_methods Layout/LineEndStringConcatenationIndentation: Enabled: false Layout/LineLength: Enabled: true Max: 100 Layout/MultilineMethodCallIndentation: Enabled: true EnforcedStyle: indented # Metrics Metrics/AbcSize: Max: 30 Metrics/BlockLength: Enabled: true Exclude: - config/**/* Metrics/MethodLength: Enabled: false # RSpec RSpec/ExampleLength: CountAsOne: - array - hash - heredoc Max: 20 RSpec/NamedSubject: Enabled: false RSpec/MultipleExpectations: Max: 10 # Style Style/Documentation: Enabled: false