Class: Genit::ScriptBuilder

Inherits:
Relativizer show all
Defined in:
lib/genit/builders/script_builder.rb

Overview

Modify script tags.

Instance Method Summary collapse

Methods inherited from Relativizer

#not_an_internal_link?

Methods inherited from BuilderBase

#build, get_number_of_base_dirs, #initialize

Constructor Details

This class inherits a constructor from Genit::BuilderBase

Instance Method Details

#build_for_page(page_name) ⇒ Object

Public: Relativize the <script src=“”> tags of a particular page.

page_name - The string filename of the page.

Returns the modified Nokogiri::XML::Document



13
14
15
# File 'lib/genit/builders/script_builder.rb', line 13

def build_for_page page_name
  build page_name,  @document.css("script")
end