vendor/symfony/twig-bundle/Resources/views/Exception/trace.html.twig line 1

Open in your IDE?
  1. <div class="trace-line-header break-long-words {{ trace.file|default(false) ? 'sf-toggle' }}" data-toggle-selector="#trace-html-{{ prefix }}-{{ i }}" data-toggle-initial="{{ style == 'expanded' ? 'display' }}">
  2.     {% if trace.file|default(false) %}
  3.         <span class="icon icon-close">{{ include('@Twig/images/icon-minus-square.svg') }}</span>
  4.         <span class="icon icon-open">{{ include('@Twig/images/icon-plus-square.svg') }}</span>
  5.     {% endif %}
  6.     {% if style != 'compact' and trace.function %}
  7.         <span class="trace-class">{{ trace.class|abbr_class }}</span>{% if trace.type is not empty %}<span class="trace-type">{{ trace.type }}</span>{% endif %}<span class="trace-method">{{ trace.function }}</span><span class="trace-arguments">({{ trace.args|format_args }})</span>
  8.     {% endif %}
  9.     {% if trace.file|default(false) %}
  10.         {% set line_number = trace.line|default(1) %}
  11.         {% set file_link = trace.file|file_link(line_number) %}
  12.         {% set file_path = trace.file|format_file(line_number)|striptags|replace({ (' at line ' ~ line_number): '' }) %}
  13.         {% set file_path_parts = file_path|split(constant('DIRECTORY_SEPARATOR')) %}
  14.         <span class="block trace-file-path">
  15.             in
  16.             <a href="{{ file_link }}">{{ file_path_parts[:-1]|join(constant('DIRECTORY_SEPARATOR')) }}{{ constant('DIRECTORY_SEPARATOR') }}<strong>{{ file_path_parts|last }}</strong></a>
  17.             {%- if style == 'compact' and trace.function %}<span class="trace-type">{{ trace.type }}</span><span class="trace-method">{{ trace.function }}</span>{% endif %}
  18.             (line {{ line_number }})
  19.         </span>
  20.     {% endif %}
  21. </div>
  22. {% if trace.file|default(false) %}
  23.     <div id="trace-html-{{ prefix ~ '-' ~ i }}" class="trace-code sf-toggle-content">
  24.         {{ trace.file|file_excerpt(trace.line, 5)|replace({
  25.             '#DD0000': 'var(--highlight-string)',
  26.             '#007700': 'var(--highlight-keyword)',
  27.             '#0000BB': 'var(--highlight-default)',
  28.             '#FF8000': 'var(--highlight-comment)'
  29.         })|raw }}
  30.     </div>
  31. {% endif %}