- Issue created by @mlncn
- πΊπΈUnited States mlncn Minneapolis, MN, USA
Here is a commit implementing this workaround:
https://git.drupalcode.org/project/octavia/-/commit/57e423072f337ae345c2...
This module admirably gets rid of useless divs that surround each item, each row, of a view. It leaves a couple more unneeded divs from around the whole view and around the item listing as a whole (that is, wrapper div, then header, then wrapper div for items and the items (now without interstitial wrappers), then footer, then closing of the wrapper div. Would be nice if this module got rid of those also. (The block and container divs outside of all that would be out of scope for this module.)
Override views-view.html.twig
to only print the divs if the view style is not plain:
{% if (style != 'plain_style') %}
<div{{ attributes.addClass(classes) }}>
{% endif %}
(Note we will probably change the style name to 'plain' if we overhaul this module with a 2.x branch, and keep our templates within the views universe while we are at it.)
Active
1.0
Code
Here is a commit implementing this workaround:
https://git.drupalcode.org/project/octavia/-/commit/57e423072f337ae345c2...