lujanfernaud/prevy

View on GitHub

Showing 1,727 of 1,727 total issues

Inconsistent indentation detected.
Open

    def error_message
      options[:message] || "is not valid"
    end
Severity: Minor
Found in app/validators/email_validator.rb by rubocop

This cops checks for inconsistent indentation.

Example:

class A
  def test
    puts 'hello'
     puts 'world'
  end
end

Missing magic comment # frozen_string_literal: true.
Open

#!/usr/bin/env ruby
Severity: Minor
Found in bin/yarn by rubocop

This cop is designed to help upgrade to Ruby 3.0. It will add the comment # frozen_string_literal: true to the top of files to enable frozen string literals. Frozen string literals may be default in Ruby 3.0. The comment will be added below a shebang and encoding comment. The frozen string literal comment is only valid in Ruby 2.3+.

Example: EnforcedStyle: when_needed (default)

# The `when_needed` style will add the frozen string literal comment
# to files only when the `TargetRubyVersion` is set to 2.3+.
# bad
module Foo
  # ...
end

# good
# frozen_string_literal: true

module Foo
  # ...
end

Example: EnforcedStyle: always

# The `always` style will always add the frozen string literal comment
# to a file, regardless of the Ruby version or if `freeze` or `<<` are
# called on a string literal.
# bad
module Bar
  # ...
end

# good
# frozen_string_literal: true

module Bar
  # ...
end

Example: EnforcedStyle: never

# The `never` will enforce that the frozen string literal comment does
# not exist in a file.
# bad
# frozen_string_literal: true

module Baz
  # ...
end

# good
module Baz
  # ...
end

Gems should be sorted in an alphabetical order within their section of the Gemfile. Gem pg_search should appear before sucker_punch.
Open

gem 'pg_search',                       '~> 2.1', '>= 2.1.2'
Severity: Minor
Found in Gemfile by rubocop

Gems should be alphabetically sorted within groups.

Example:

# bad
gem 'rubocop'
gem 'rspec'

# good
gem 'rspec'
gem 'rubocop'

# good
gem 'rubocop'

gem 'rspec'

# good only if TreatCommentsAsGroupSeparators is true
# For code quality
gem 'rubocop'
# For tests
gem 'rspec'

Avoid vendor prefixes.
Open

  -webkit-box-sizing: border-box;

0.032 should be written without a leading zero as .032
Open

  background: linear-gradient(rgba(75, 12, 178, 0.0095), rgba(75, 12, 178, 0.032));

Color literals like rgba(0, 0, 0, 0.35) should only be used in variable declarations; they should be referred to via variable everywhere else.
Open

  text-shadow: 1px 1px 0 rgba(0, 0, 0, .35);

Shorthand form for property padding should be written more concisely as .5rem .5rem .31rem instead of .5rem .5rem .31rem .5rem
Open

    padding: .5rem .5rem .31rem .5rem;

Properties should be ordered border-bottom, font-size, line-height, padding
Open

  padding: 1.5rem 3rem;

Properties should be ordered border-bottom-right-radius, border-top-right-radius
Open

    border-top-right-radius: $box-radius !important;

0.5 should be written without a leading zero as .5
Open

  margin-bottom: 0.5rem;

Selector event-box__attending should be written in lowercase with hyphens
Open

.event-box__attending {

Selector event-box-big__data should be written in lowercase with hyphens
Open

.event-box-big__data {

0.15 should be written without a leading zero as .15
Open

  border: 1px solid rgba(0, 0, 0, 0.15);

Selector user-box__image should be written in lowercase with hyphens
Open

.user-box__image {

Expected item on line 74 to appear before line 71. Rule sets should be ordered as follows: @extends, @includes without @content, properties, @includes with @content, nested rule sets
Open

  @include section-borders;

Properties should be ordered padding-bottom, padding-top
Open

  padding-top: 4rem;

Color literals like #dee0e3 should only be used in variable declarations; they should be referred to via variable everywhere else.
Open

  border: 1px solid #dee0e3;

Properties should be ordered padding-bottom, padding-top
Open

  padding-top: .5rem;

Inconsistent indentation detected.
Open

    def updated_data
      @_updated_data ||= @event.updated_fields.keys.map do |field_name|
        simplified_name_for field_name
      end
    end

This cops checks for inconsistent indentation.

Example:

class A
  def test
    puts 'hello'
     puts 'world'
  end
end

Missing top-level class documentation comment.
Open

class EmailValidator < ActiveModel::EachValidator
Severity: Minor
Found in app/validators/email_validator.rb by rubocop

This cop checks for missing top-level documentation of classes and modules. Classes with no body are exempt from the check and so are namespace modules - modules that have nothing in their bodies except classes, other modules, or constant definitions.

The documentation requirement is annulled if the class or module has a "#:nodoc:" comment next to it. Likewise, "#:nodoc: all" does the same for all its children.

Example:

# bad
class Person
  # ...
end

# good
# Description/Explanation of Person class
class Person
  # ...
end
Severity
Category
Status
Source
Language