Class: Quotes
- Inherits:
-
Object
- Object
- Quotes
- Defined in:
- lib/rus_typograf/quotes.rb
Overview
Класс для работы с кавычками
Instance Method Summary collapse
-
#replace_quote(text) ⇒ Object
Замена двойных кавычек на кавычки елочки.
Instance Method Details
#replace_quote(text) ⇒ Object
Замена двойных кавычек на кавычки елочки
4 5 6 7 |
# File 'lib/rus_typograf/quotes.rb', line 4 def replace_quote(text) text = text.gsub(/[<][<]/, '«') text = text.gsub(/[>][>]/, '»') end |