Class: Jekyll::SourceMapPage
- Inherits:
-
Page
- Object
- Page
- Jekyll::SourceMapPage
- Defined in:
- lib/jekyll/source_map_page.rb
Overview
A Jekyll::Page subclass to manage the source map file associated with a given scss / sass page.
Instance Method Summary collapse
- #asset_file? ⇒ Boolean
- #ext ⇒ Object
-
#initialize(css_page) ⇒ SourceMapPage
constructor
Initialize a new SourceMapPage.
-
#inspect ⇒ Object
@return the object as a debug String.
- #render_with_liquid? ⇒ Boolean
- #source_map(map) ⇒ Object
Constructor Details
#initialize(css_page) ⇒ SourceMapPage
Initialize a new SourceMapPage.
10 11 12 13 14 15 16 17 18 |
# File 'lib/jekyll/source_map_page.rb', line 10 def initialize(css_page) @site = css_page.site @dir = css_page.dir @data = css_page.data @name = css_page.basename + ".css.map" process(@name) Jekyll::Hooks.trigger :pages, :post_init, self end |
Instance Method Details
#asset_file? ⇒ Boolean
28 29 30 |
# File 'lib/jekyll/source_map_page.rb', line 28 def asset_file? true end |
#ext ⇒ Object
24 25 26 |
# File 'lib/jekyll/source_map_page.rb', line 24 def ext ".map" end |
#inspect ⇒ Object
@return the object as a debug String.
37 38 39 |
# File 'lib/jekyll/source_map_page.rb', line 37 def inspect "#<#{self.class} @name=#{name.inspect}>" end |
#render_with_liquid? ⇒ Boolean
32 33 34 |
# File 'lib/jekyll/source_map_page.rb', line 32 def render_with_liquid? false end |
#source_map(map) ⇒ Object
20 21 22 |
# File 'lib/jekyll/source_map_page.rb', line 20 def source_map(map) self.content = map end |