We all love JS, don't we? Yes, we do. But, unfortunately, JS does not allow us to insert variables inside a string. We must close our quotes, concatenate with a + operator, and live our lives. What this tiny script does is replace anything inside #{ } for a variable. Ruby users know what this is.
Let's say, you have two variables:
var mood = "nice";