Output escaped JS strings when compiling

The compiler wasn't escaping javascript string literals.