module Roda::RodaPlugins::Render::ClassMethods

def freeze

access to the layout method to improve the performance of view.
If using compiled methods and there is an optimized layout, speed up
def freeze
  begin
    _freeze_layout_method
  rescue
    # This is only for optimization, if any errors occur, they can be ignored.
    # One possibility for error is the app doesn't use a layout, but doesn't
    # specifically set the :layout=>false plugin option.
    nil
  end
  # Optimize _call_optimized_template_method if you know all templates
  # are going to be using fixed locals.
  if render_opts[:assume_fixed_locals] && !render_opts[:check_template_mtime]
    include AssumeFixedLocalsInstanceMethods
  end
  super
end