File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -2,7 +2,7 @@ import { createApi } from "@reduxjs/toolkit/query/react";
22
33import { axiosBaseQuery } from "../services/httpService" ;
44
5- const programId = import . meta. env . VITE_PROGRAM_ID || "app02 " ;
5+ const programId = import . meta. env . VITE_PROGRAM_ID || "app01 " ;
66console . log ( "programId == " , programId ) ;
77const baseApiPath = `/cws/${ programId } /api` ;
88
Original file line number Diff line number Diff line change 1+ import { useSelector } from 'react-redux' ;
2+ import { selectRoomId } from './commonUiSelectors' ;
3+
4+ export const useRoomId = ( ) => {
5+ return useSelector ( selectRoomId ) ;
6+ } ;
Original file line number Diff line number Diff line change 1+ import { createSelector } from '@reduxjs/toolkit' ;
2+ import { RootState } from '../store' ;
3+
4+
5+ export const selectRoomId = createSelector (
6+ ( state : RootState ) => state . commonUI ,
7+ ( commonUI ) => commonUI . roomId
8+ ) ;
Original file line number Diff line number Diff line change @@ -9,6 +9,7 @@ const commonUiSlice = createSlice({
99 state . roomId = action . payload ;
1010 } ,
1111
12+
1213 // resetState: () => {
1314 // // This is here in order to provide an action name to trigger store reset
1415 // // in root store reducer
You can’t perform that action at this time.
0 commit comments