Go to content

The Things Scala js Does to Make Your Code Fast - by Sébastien Doeraene

This talk was recorded at Scala Days New York, 2016. Follow along on Twitter @scaladays and on the website for more information http://scaladays.org/. Abstract: One of the strengths of Scala.js is its run-time performance. Compiled Scala.js programs typically run on par with equivalent, hand-written JavaScript code. To achieve this, Scala.js features an advanced optimizer. In this talk, we will explore some typical Scala.js code snippets, and see what the optimizer makes of them. In the process, we will give insights about the code patterns that it can optimize away, as well as things it cannot (yet) eliminate. Attendees will take away keys to write efficient Scala.js code. In particular, we will see that idiomatic Scala code is not to be feared (e.g., for loops, or maps/filters). Attendees are expected to be familiar with Scala (not necessarily Scala.js) and to be able to read JavaScript. No compiler knowledge is required; we will stay at the source code level, showing what the optimizer does without explaining how.

May 9, 2016