Class: ContextInspector
- Inherits:
-
Liquid::Tag
- Object
- Liquid::Tag
- ContextInspector
- Defined in:
- lib/jekyll_context_inspector.rb
Instance Method Summary collapse
Instance Method Details
#render(context) ⇒ Object
12 13 14 15 16 17 18 19 20 21 22 |
# File 'lib/jekyll_context_inspector.rb', line 12 def render(context) @logger = PluginMetaLogger.instance.new_logger(self, PluginMetaLogger.instance.config) site = context.registers[:site] inspector_enabled = site.config["context_inspector"] return if inspector_enabled.nil? || !inspector_enabled mode = site.config["env"]["JEKYLL_ENV"] return unless inspector_enabled == "force" || mode == "development" dump_info(context) end |