Sha256: 44e624978a296e5cdf351a8516b4d95284b08188d0b18773a6e7d493acc93602
Contents?: true
Size: 625 Bytes
Versions: 22
Compression:
Stored size: 625 Bytes
Contents
# frozen_string_literal: true require_relative 'short_string' module Dsu module Support module Descriptable class << self def included(base) base.extend(ClassMethods) end end def short_description return '' if description.blank? self.class.short_description(string: description) end module ClassMethods include ShortString def short_description(string:, count: ShortString::SHORT_STRING_MAX_COUNT, elipsis: '...') short_string(string: string, count: count, elipsis: elipsis) end end end end end
Version data entries
22 entries across 22 versions & 1 rubygems