instance method
years_since
Ruby on Rails 6.1.7.10
Since v4.0.13Signature
years_since(years)
Returns a new date/time the specified number of years in the future.
Parameters
-
yearsreq
Source
# File activesupport/lib/active_support/core_ext/date_and_time/calculations.rb, line 112
def years_since(years)
advance(years: years)
end
Defined in activesupport/lib/active_support/core_ext/date_and_time/calculations.rb line 112
· View on GitHub
· Improve this page
· Find usages on GitHub
Defined in DateAndTime::Calculations