Jak pokazać ... po długich notach js html h1

/*Css*/

.text {
  display: block;
  width: 100px;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}

/* html */
<span class="text">Hello world this is a long sentence</span>
Wandering Wryneck