Trouble with fragment identifiers in a SPA

Hey. I am aware how it works in general and for example with static pages the fragment linking works fine, even across pages.

<!DOCTYPE html>
<html>
<body>

  <p style="height:2000px">
    My first paragraph.
    <a href="#foo"> Go to second paragraph </a>
  </p>

  <p id="foo">My second paragraph.</p>

</body>
</html>

What I am struggling is why it doesn’t work in the clojurescript SPA described above.