/**
  * Wrap template with the debugging hints in comments
  *
  * @param Template $subject
  * @param string $result
  *
  * @return string
  */
 public function afterToHtml(Template $subject, $result)
 {
     if ($this->scopeConfig->getValue(self::XML_PATH_DEBUG_TEMPLATE_HINTS, ScopeInterface::SCOPE_STORE) && $this->appState->getMode() === State::MODE_DEVELOPER) {
         $name = $subject->getNameInLayout();
         $template = $subject->getTemplateFile();
         $class = get_class($subject);
         $result = "<!-- BEGIN {$name} using {$template} \n" . $class . '-->' . $result . "<!-- END {$name} using {$template} -->";
     }
     return $result;
 }