Class: I18n::Tasks::Scanners::ErbAstScanner
- Inherits:
-
RubyAstScanner
- Object
- Scanner
- FileScanner
- RubyAstScanner
- I18n::Tasks::Scanners::ErbAstScanner
- Defined in:
- lib/i18n/tasks/scanners/erb_ast_scanner.rb
Overview
Scan for I18n.translate calls in ERB-file better-html and ASTs
Constant Summary collapse
- DEFAULT_REGEXP =
/<%(={1,2}|-|\#|%)?(.*?)([-=])?%>/m.freeze
Constants inherited from RubyAstScanner
RubyAstScanner::MAGIC_COMMENT_PREFIX
Instance Attribute Summary
Attributes inherited from FileScanner
Instance Method Summary collapse
-
#initialize(**args) ⇒ ErbAstScanner
constructor
A new instance of ErbAstScanner.
Methods included from RelativeKeys
Methods inherited from FileScanner
Methods inherited from Scanner
Constructor Details
#initialize(**args) ⇒ ErbAstScanner
Returns a new instance of ErbAstScanner.
11 12 13 14 |
# File 'lib/i18n/tasks/scanners/erb_ast_scanner.rb', line 11 def initialize(**args) super(**args) @ruby_parser = LocalRubyParser.new(ignore_blocks: true) end |