I think the best solution here is to use show bibliography: none:
context if query(cite) == () {
show bibliography: none
bibliography(
"Typst/Literatur.yaml",
style: "institute-of-electrical-and-electronics-engineers",
title: none,
)
} else {
pagebreak()
bibliography(
"Typst/Literatur.yaml",
style: "institute-of-electrical-and-electronics-engineers",
)
}
hide() will not display the bibliography, but still occupy space. That can have negative effects when e.g. the last page is almost full, so the hidden bibliography forces an extra empty page. (In this concrete case, if you remove the heading the empty bibliography shouldn’t use space anyway, but in general that can be an issue.)
using show bibliography: none will load the bib file, but remove the heading and rendered bibliography from the document, so you get both at the same time.