instance method indentation

Ruby on Rails 8.1.2

Since v6.0.6 Private

Available in: v6.0.6 v6.1.7.10 v7.0.10 v7.1.6 v7.2.3 v8.0.4 v8.1.2

Signature

indentation()

Returns a string corresponding to the current indentation level (i.e. 2 * @indentation spaces). See also #with_indentation, which can be used to manage the indentation level.

Source
# File railties/lib/rails/generators/actions.rb, line 495
        def indentation # :doc:
          "  " * @indentation
        end

Defined in railties/lib/rails/generators/actions.rb line 495 · View on GitHub · Improve this page · Find usages on GitHub

Defined in Rails::Generators::Actions

Type at least 2 characters to search.

↑↓ navigate · open · esc close