Class: ActionView::Helpers::JqueryHelper::JavaScriptGenerator

Inherits:
Object
  • Object
show all
Defined in:
lib/action_view/helpers/jquery_helper/generator.rb

Defined Under Namespace

Modules: GeneratorMethods

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(context, &block) ⇒ JavaScriptGenerator

:nodoc:



7
8
9
10
11
12
13
14
# File 'lib/action_view/helpers/jquery_helper/generator.rb', line 7

def initialize(context, &block) #:nodoc:
  @context, @lines = context, []
  def @lines.encoding() last.to_s.encoding end
  include_helpers_from_context
  @context.with_output_buffer(@lines) do
    @context.instance_exec(self, &block)
  end
end

Class Method Details

.encodingObject



9
# File 'lib/action_view/helpers/jquery_helper/generator.rb', line 9

def @lines.encoding() last.to_s.encoding end