Class: Jekyll::StrapiStaticFile

Inherits:
StaticFile
  • Object
show all
Defined in:
lib/jekyll/tags/strapiimagefilter.rb

Instance Method Summary collapse

Constructor Details

#initialize(site, base, dir, name, collection = nil) ⇒ StrapiStaticFile

Returns a new instance of StrapiStaticFile.



6
7
8
9
10
11
12
13
14
15
# File 'lib/jekyll/tags/strapiimagefilter.rb', line 6

def initialize(site, base, dir, name, collection = nil)
  @site = site
  @base = base
  @dir  = dir
  @name = name
  @collection = collection
  # TODO: Check if user can change 'assets' path
  @relative_path = File.join(*["assets", @name].compact)
  @extname = File.extname(@name)
end