# File lib/mini_profiler/profiler.rb, line 111 def generate_html(page_struct, env, result_json = page_struct.to_json) html = MiniProfiler.share_template.dup html.sub!('{path}', "#{env['RACK_MINI_PROFILER_ORIGINAL_SCRIPT_NAME']}#{@config.base_url_path}") html.sub!('{version}', MiniProfiler::ASSET_VERSION) html.sub!('{json}', result_json) html.sub!('{includes}', get_profile_script(env)) html.sub!('{name}', page_struct[:name]) html.sub!('{duration}', page_struct.duration_ms.round(1).to_s) html end