Method: XRay::HTML::Parser#parse_text
- Defined in:
- lib/html/parser.rb
#parse_text ⇒ Object
68 69 70 71 72 73 74 75 76 77 78 |
# File 'lib/html/parser.rb', line 68 def parse_text text = '' until text_end? do text << '<' if @scanner.skip(/</) text << "#{@scanner.scan(TEXT)}" # TODO: make this detection a rule parse_warn "'#{$~}' not escaped" if text =~ /<|>/ end TextElement.new text end |