1

/*Show a label and grey overlay or hide both on connection change. */

var g_StatusMessageTypes = {
        "authenticated": msg => translate("Connection to the server has been authenticated."),
        "connected": msg => translate("Connected to the server."),
        "disconnected": msg => translate("Connection to the server has been lost.") + "\n" +
                        // Translation: States the reason why the client disconnected from the server.
                        sprintf(translate("Reason: %(reason)s."), { "reason": getDisconnectReason(msg.reason) }) + "\n" +
                        translate("The game has ended."),
        "waiting_for_players": msg => translate("Waiting for other players to connect..."),
        "join_syncing": msg => translate("Synchronising gameplay with other players..."),
        "active": msg => ""
    };

As code above, what "=>" means? Someone help me?

Kid
  • 77
  • 1
  • 6
  • [Arrow Function](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Functions/Arrow_functions) – adeneo Jan 10 '16 at 05:24
  • That's an arrow function expression. This article might help : https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Functions/Arrow_functions – flopperJ Jan 10 '16 at 05:49

0 Answers0