# Please lose the divs in the lists

**URL:** https://meta.discourse.org/t/please-lose-the-divs-in-the-lists/39518
**Category:** Feature
**Created:** [13 februari 2016 om 07:55 UTC](https://meta.discourse.org/t/please-lose-the-divs-in-the-lists/39518 "2016-02-13T07:55:47Z")
**Posts on this page:** 4
**Page:** 1

<div class="post-metadata">

### Author: ![Mittineague](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/mittineague/32/114259_2.png) [@Mittineague](https://meta.discourse.org/u/Mittineague)
#### Post date: [13 februari 2016 om 07:55 UTC](https://meta.discourse.org/t/please-lose-the-divs-in-the-lists/39518/1 "2016-02-13T07:55:47Z")

</div>

Because of my experimenting with plugin outlets. I found two cases of div tags having a list as a parent.

The “breadcrumb” and the “menu links”

```plaintext
<ol class="ember-view category-breadcrumb" id="ember4770">
  <li class="ember-view no-category has-drop bullet" id="ember4772">
    <a aria-expanded="false" aria-label="Display category list" style="background-color: #eee; color: #333" data-ember-action="4774" class="badge-category home" href="">all categories</a>
  <a style="background-color: #eee; color: #333" class="badge-category category-dropdown-button home" data-ember-action="4776" href=""><i class="fa fa-caret-right"></i></a>
  <section class="hidden category-dropdown-menu chooser">
      <div class="cat"><a href="/" class="badge-category home" data-drop-close="true">all categories</a></div>
    </section>
  </li>

  <div class="ember-view bread-crumbs-right-outlet tag-selector" id="ember4773">

    <li class="ember-view tag-drop no-category bullet tag_all" id="ember4778"><!----></li>

  </div>

<div class="clear"></div>

</ol>

```

.

```plaintext
<ul class="menu-links columned">
  <li><a href="/" class="ember-view d-link latest-topics-link" id="ember4830">Latest</a></li>
  <li><a href="/new" class="ember-view d-link new-topics-link" id="ember4837">New</a></li>
  <li><a href="/unread" class="ember-view d-link unread-topics-link" id="ember4845">Unread (2)</a></li>
  <li><a href="/top" class="ember-view d-link top-topics-link" id="ember4831">Top</a></li>
  <li><a href="/badges" class="ember-view d-link badge-link" id="ember4860">Badges</a></li>
  <li><a href="/users" class="ember-view d-link user-directory-link" id="ember4876">Users</a></li>

  <div class="ember-view site-map-links-outlet tag-cloud-link" id="ember4836">

    <li><a href="/tags" class="ember-view" id="ember4885">Tags</a></li>

  </div>

  <div class="clearfix"></div>

</ul>

```

I guess it doesn’t break anything, perhaps because browsers do well at “guessing” what the mark-up should be.

Unlike misplaced tags inside of tables, they don’t show up “outside”

```plaintext
    <ol>
      <li>ol list item</li>
      <li>ol list item</li>
    <div>div in an ol</div>
      <li>ol list item</li>
    <div><div>div in a div in an ol</div></div>
      <li>ol list item</li>
    <div><li>list item in a div in an ol</li></div>
      <li>ol list item</li>
    </ol>
    <ul>
      <li>ul list item</li>
      <li>ul list item</li>
    <div>div in a ul</div>
      <li>ul list item</li>
    <div><div>div in a div in a ul</div></div>
      <li>ul list item</li>
    <div><li>list item in a div in a ul</li></div>
      <li>ul list item</li>
    </ul>

```

 ![](https://global.discourse-cdn.com/meta/original/3X/d/f/dfae18c972878d6111c13afbe7294ced200b87a2.png) 

I don’t know what would be better, having the divs outside of the lists, or changing the divs to list items, (other?).

But I think even if it hasn’t bitten anyone yet there’s a chance it will eventually.

---

<div class="post-metadata">

### Author: ![sam](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/sam/32/102149_2.png) [@sam](https://meta.discourse.org/u/sam)
#### Post date: [13 februari 2016 om 09:48 UTC](https://meta.discourse.org/t/please-lose-the-divs-in-the-lists/39518/2 "2016-02-13T09:48:52Z")

</div>

Isn’t this essentially this bug?

> [@Plugin-outlet incorrectly handles multiple plugins at the same outlet](https://meta.discourse.org/t/plugin-outlet-incorrectly-handles-multiple-plugins-at-the-same-outlet/32206):
>
> Wrong code is: Must be Ember.ContainerView.extend({tagName: ''}) instead of Ember.ContainerView. The current wrong code breaks HTML markup in cases where HTML syntax does not allow wrapper DIV tag. An example is admin-menu plugin outlet: If there are multiple admin-menu connectors then Discourse wrongly renders them as: \<ul\> \<!-- standard menu items: --\> \<li\>\</li\> \<li\>\</li\> \<!-- admin-menu connectors: --\> \<div\> \<li\>\</li\> \<li\>\</li\> \</div\> \</ul\>

---

<div class="post-metadata">

### Author: ![Mittineague](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/mittineague/32/114259_2.png) [@Mittineague](https://meta.discourse.org/u/Mittineague)
#### Post date: [13 februari 2016 om 11:10 UTC](https://meta.discourse.org/t/please-lose-the-divs-in-the-lists/39518/3 "2016-02-13T11:10:56Z")

</div>

> [@sam](#):
>
> Isn’t this essentially this bug?

Looking into it a bit more, I think so.

I was thinking it might be simply moving the outlets to a different place in the hbs file.

But both of those are “components” used in other hbs files.

Not an easy one.

Well I guess as long as it isn’t breaking anything and the issue is known (in case something does have a problem with it) it’s a back-burner concern. Much more pressing things to attend to,

---

<div class="post-metadata">

### Author: ![sam](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/sam/32/102149_2.png) [@sam](https://meta.discourse.org/u/sam)
#### Post date: [28 november 2016 om 02:59 UTC](https://meta.discourse.org/t/please-lose-the-divs-in-the-lists/39518/4 "2016-11-28T02:59:07Z")

</div>


