test.html 766 Bytes
<!DOCTYPE html>
<html>
<head>
<style>
#ref {
  background: orange;
  width: 50px;
  height: 50px;
}

#pop {
  background: green;
  width: 50px;
  height: 50px;
}

.container {
  align-items: center;
  background: blue;
  border: 20px solid red;
  display: flex;
  height: 400px;
  justify-content: center;
  margin: auto;
  position: relative;
  width: 400px;
}
</style>
</head>
<body>
    <div class="container">
      <div id="ref" aria-describedby="pop">ref</div>
      <div id="pop" role="tooltip">pop</div>
    </div>

    <script src="../../dist/umd/popper.js"></script>
    <script>
    const refEl = document.getElementById("ref");
    const popEl = document.getElementById("pop");

    const popper = new Popper(refEl, popEl);
    </script>
</body>
</html>