Class: Jekyll::Prefetch
- Inherits:
-
Liquid::Block
- Object
- Liquid::Block
- Jekyll::Prefetch
- Includes:
- AssetPages::Jekyll::LiquidHelper
- Defined in:
- lib/asset_pages/jekyll/plugins/prefetch.rb
Constant Summary collapse
- AssetPathPattern =
Regexp.new("#{Liquid::QuotedFragment}+")
Constants included from AssetPages::Jekyll::LiquidHelper
AssetPages::Jekyll::LiquidHelper::Root
Instance Method Summary collapse
Methods included from AssetPages::Jekyll::LiquidHelper
Instance Method Details
#render(context) ⇒ Object
27 28 29 30 31 32 33 34 35 36 37 38 39 |
# File 'lib/asset_pages/jekyll/plugins/prefetch.rb', line 27 def render(context) @context = context super.split("\n", -1).each do |line| , line = AssetTag.(line) line.scan(AssetPathPattern) do |path| asset_path(path, .merge(debug: false)) end end "" end |