diff options
author | Joffrey BION <joffrey.bion@gmail.com> | 2017-05-21 20:20:45 +0200 |
---|---|---|
committer | Joffrey BION <joffrey.bion@gmail.com> | 2017-05-22 00:23:02 +0200 |
commit | c03e68041e0f444e18a895058afbdf0d68759517 (patch) | |
tree | 6e31f9726d36e746f43c7856cebff8c861577e31 /frontend/src/redux/games.js | |
parent | Clean name in websocket.js (diff) | |
download | seven-wonders-c03e68041e0f444e18a895058afbdf0d68759517.tar.gz seven-wonders-c03e68041e0f444e18a895058afbdf0d68759517.tar.bz2 seven-wonders-c03e68041e0f444e18a895058afbdf0d68759517.zip |
Update prettier config and reformat
Here's the discussion summary:
- single quote, because that's what I'm used to in the JS world
- trailing comma, to avoid unnecessary git changes
- print-width 120, because 120 still doesn't require to scroll horizontally, and vertical space is precious
Diffstat (limited to 'frontend/src/redux/games.js')
-rw-r--r-- | frontend/src/redux/games.js | 22 |
1 files changed, 11 insertions, 11 deletions
diff --git a/frontend/src/redux/games.js b/frontend/src/redux/games.js index a7115dcc..9ef0e7cd 100644 --- a/frontend/src/redux/games.js +++ b/frontend/src/redux/games.js @@ -1,12 +1,12 @@ -import Immutable from "seamless-immutable"; +import Immutable from 'seamless-immutable'; export const types = { - UPDATE_GAMES: "GAME/UPDATE_GAMES", - REQUEST_CREATE_GAME: "GAME/REQUEST_CREATE_GAME", - REQUEST_JOIN_GAME: "GAME/REQUEST_JOIN_GAME", - REQUEST_START_GAME: "GAME/REQUEST_JOIN_GAME", - ENTER_LOBBY: "GAME/ENTER_LOBBY", - ENTER_GAME: "GAME/ENTER_GAME" + UPDATE_GAMES: 'GAME/UPDATE_GAMES', + REQUEST_CREATE_GAME: 'GAME/REQUEST_CREATE_GAME', + REQUEST_JOIN_GAME: 'GAME/REQUEST_JOIN_GAME', + REQUEST_START_GAME: 'GAME/REQUEST_JOIN_GAME', + ENTER_LOBBY: 'GAME/ENTER_LOBBY', + ENTER_GAME: 'GAME/ENTER_GAME', }; export const actions = { @@ -14,16 +14,16 @@ export const actions = { requestJoinGame: gameId => ({ type: types.REQUEST_JOIN_GAME, gameId }), requestCreateGame: gameName => ({ type: types.REQUEST_CREATE_GAME, - gameName + gameName, }), requestStartGame: () => ({ type: types.REQUEST_START_GAME }), enterLobby: lobby => ({ type: types.ENTER_LOBBY, lobby: Immutable(lobby) }), - enterGame: () => ({ type: types.ENTER_GAME }) + enterGame: () => ({ type: types.ENTER_GAME }), }; const initialState = Immutable.from({ all: {}, - current: "" + current: '', }); export default (state = initialState, action) => { @@ -31,7 +31,7 @@ export default (state = initialState, action) => { case types.UPDATE_GAMES: return Immutable.merge(state, { all: action.games }, { deep: true }); case types.ENTER_LOBBY: - return state.set("current", action.lobby.id); + return state.set('current', action.lobby.id); default: return state; } |