In vanilla Obsidian, in order for blockID to work there needs to be a line break after the blockID itself. Without it, the blockID link only points to the beginning of the file (containing the block).
This is usually annoying because we don’t need to see the blockID and this line when reviewing content. There has been interest in hiding the blockID here:
For completeness, we can hide the (next) line that is required for blockID to function properly with this CSS:
.cm-line:has(.cm-blockid) + .cm-line { display: none; }
For people that don’t know CSS (like me): this means in English "select the cm-line
element that is preceeded by another cm-line
element, which has the cm-blockid
element; then do not display it "