Wandledi - You don't need template languages!



html
<html>
  <head>
    <title>User Overview</title>
  </head>
  <body>
    <h1>User Overview</h1>
    <ul class="users">
      <li>Hans</li>
    </ul>
  </body>
</html>

+

scala
val users = Seq("Clemens", "Markus", "Mathias", "Seb")
val currentUser = Some("Markus")

$("ul.users li").foreachIn(users) { (li, user) =>
  li.text = user
  currentUser.filter(user ==).foreach(cu =>
    li.setAttribute("class", "current"))
}

||

html
<html>
  <head>
    <title>User Overview</title>
  </head>
  <body>
    <h1>User Overview</h1>
    <ul class="users">
      <li>Clemens</li>
      <li class="current">Markus</li>
      <li>Mathias</li>
      <li>Seb</li>
    </ul>
  </body>
</html>