Problem/Motivation

First of all I would like to compliment the maintainers of the theme. The theme is attractive and loads fast. Thank you for your work.

We used the theme on a project and noticed that the Main Menu and Breadcrumbs (contrib module) are given H2 tags on a page. I am wondering why this is done? From an SEO perspective this is not beneficial.

I do not see this as a bug, so I filed it as a support request. Please change as necessary.

Issue fork drupal-3456388

Command icon Show commands

Start within a Git clone of the project using the version control instructions.

Or, if you do not have SSH keys set up on git.drupalcode.org:

Comments

platinum1 created an issue. See original summary.

quietone’s picture

Version: 11.0.x-dev » 11.x-dev
saurav-drupal-dev’s picture

You're right that using H2 tags for the Main Menu and Breadcrumbs could have SEO implications, as it may disrupt the heading hierarchy of the page.

The H2 tags are likely coming from the theme's default Twig template for these elements. To fix this, you can override the menu.html.twig or breadcrumb.html.twig file in your theme:

{# menu--main.html.twig #}
<nav class="menu">
  <ul>
    {% for item in items %}
      <li>{{ item.title }}</li>
    {% endfor %}
  </ul>
</nav>

This change ensures proper semantic structure while maintaining accessibility. Don't forget to clear the cache after applying the changes!
Let me know if you'd like further assistance with testing or creating a patch also we can directly replace H2 with div.

niharika.s’s picture

Assigned: Unassigned » niharika.s
niharika.s’s picture

Assigned: niharika.s » Unassigned
saurav-drupal-dev’s picture

anyone has any suggestion on it?

platinum1’s picture

Thank you for your confirmation @saurav-drupal-dev.

I am surprised that nobody else is taking an issue with this.

Version: 11.x-dev » main

Drupal core is now using the main branch as the primary development branch. New developments and disruptive changes should now be targeted to the main branch.

Read more in the announcement.

quietone’s picture

Status: Active » Fixed

It looks like this has been answered.

The Drupal Core issue queue is not the ideal place for support requests. The 'support request' option is there for filing support issues for contributed modules and themes. There are several support options listed on our Support page, including the Drupal Forums and Drupal Answers. There is also Drupal Slack. You may get better replies in one of those places.

I am closing this per the guidance in Handle or refer a support request in an issue.

Now that this issue is closed, review the contribution record.

As a contributor, attribute any organization that helped you, or if you volunteered your own time.

Maintainers, credit people who helped resolve this issue.

platinum1’s picture

Dear @quietone, I do not perceive my original post as a support request for Drupal Forums or Drupal Answers. I have described a shortcoming in a core theme, which can negatively affect the SEO of all users utilizing the theme. @saurav-drupal-dev not only agreed with the possible SEO implications, but indicated where the problem is coming from. That does not mean that a question has been answered, there was none in the first place.

FWIW, I think the theme should be changed in this regard. If the community does not agree, so bet it.

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.