Class: String

Inherits:
Object
  • Object
show all
Defined in:
lib/locomotive/mounter/utils/string.rb

Overview

String

Instance Method Summary collapse

Instance Method Details

:nodoc



7
8
9
10
# File 'lib/locomotive/mounter/utils/string.rb', line 7

def permalink(underscore = false)
  permalink = self.to_ascii.parameterize
  underscore ? permalink.underscore : permalink
end

#permalink!(underscore = false) ⇒ Object Also known as: parameterize!



12
13
14
# File 'lib/locomotive/mounter/utils/string.rb', line 12

def permalink!(underscore = false)
  replace(self.permalink(underscore))
end