Option to add block to Query Loop Block visible only when query has results
What problem does this address?
Example: I have a headline and a list of posts selected following a specific criteria. If no posts match the criteria, the headline is displayed with an optional “no posts found” text. Instead, I would prefer not to show the headline at all so that entire section just disappears from the page.
What is your proposed solution?
Add a block exactly like the "No results" block that would only display when query has results. Possibly allow that block to be duplicated so that you can add content before and after the results.
Thanks for the suggestion, @EricDu. The same idea, a "With results" counterpart to the "No results" block or an option to hide the whole loop when there are no results, is now being actively discussed in #83029, and someone has offered to build it. I'm closing this as a duplicate so the conversation stays in one place. Please add your use case there.