Globalize Jekyll's Filters.
As it stands Jekyll does not globalize it's filters. So anybody wishing to go into Jekyll's context to process their own Liquid (say in a plugin) may be taken aback when they find out that Jekyll's filters are not available. See: jekyll/jekyll-assets#252.
This commit is contained in:
parent
8144e7620f
commit
1e74c7a547
|
@ -402,3 +402,7 @@ module Jekyll
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
Liquid::Template.register_filter(
|
||||||
|
Jekyll::Filters
|
||||||
|
)
|
||||||
|
|
|
@ -52,7 +52,6 @@ module Jekyll
|
||||||
document.trigger_hooks(:pre_render, payload)
|
document.trigger_hooks(:pre_render, payload)
|
||||||
|
|
||||||
info = {
|
info = {
|
||||||
:filters => [Jekyll::Filters],
|
|
||||||
:registers => { :site => site, :page => payload['page'] }
|
:registers => { :site => site, :page => payload['page'] }
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue