ES6

    Scala.js

    1. xhr.open("GET",
    2. "https://api.twitter.com/1.1/search/" +
    3. )
    4. xhr.onload = { (e: Event) =>
    5. if (xhr.status == 200) {
    6. $("#tweets").html(parseTweets(r))
    7. }