Add subword mode for scala and javascript.