Skip to content

Commit

Permalink
Merge pull request #3023 from gdg-x/redux
Browse files Browse the repository at this point in the history
Update Redux
  • Loading branch information
abraham authored Mar 2, 2024
2 parents 62ce8a6 + cf3628b commit 18141b1
Show file tree
Hide file tree
Showing 4 changed files with 106 additions and 104 deletions.
96 changes: 47 additions & 49 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@
"@polymer/polymer": "^3.5.1",
"@power-elements/lazy-image": "^2.2.0",
"@radi-cho/star-rating": "git+https://[email protected]/abraham/star-rating.git#polymer-3",
"@reduxjs/toolkit": "^1.9.6",
"@reduxjs/toolkit": "^2.2.1",
"@vaadin/router": "^1.7.5",
"firebase": "^10.8.1",
"lit": "^2.8.0",
Expand Down
56 changes: 2 additions & 54 deletions src/store/index.ts
Original file line number Diff line number Diff line change
@@ -1,64 +1,12 @@
import { configureStore } from '@reduxjs/toolkit';
import { authReducer } from './auth/reducers';
import { blogReducer } from './blog/reducers';
import { dialogsReducer } from './dialogs/reducers';
import { featuredSessionsReducer } from './featured-sessions/reducers';
import feedback from './feedback';
import { filtersReducer } from './filters/reducers';
import { galleryReducer } from './gallery/reducers';
import { membersReducer } from './members/reducers';
import notificationPermission from './notification-permission';
import { notificationsSubscribersReducer } from './notifications-subscribers/reducers';
import { notificationsUsersReducer } from './notifications-users/reducers';
import partners from './partners';
import { potentialPartnersReducer } from './potential-partners/reducers';
import { previousSpeakersReducer } from './previous-speakers/reducers';
import { scheduleReducer } from './schedule/reducers';
import { sessionsReducer } from './sessions/reducers';
import snackbars from './snackbars';
import { speakersReducer } from './speakers/reducers';
import { subscribeReducer } from './subscribe/reducers';
import { teamsReducer } from './teams/reducers';
import { ticketsReducer } from './tickets/reducers';
import { uiReducer } from './ui/reducers';
import { updateNotificationsSubscribersReducer } from './update-notifications-subscribers/reducers';
import { updateNotificationsUsersReducer } from './update-notifications-users/reducers';
import { userReducer } from './user/reducers';
import { videosReducer } from './videos/reducers';
import { reducers } from './reducers';

export const store = configureStore({
middleware: (getDefaultMiddleware) =>
getDefaultMiddleware({
serializableCheck: false,
}),
reducer: {
auth: authReducer,
blog: blogReducer,
dialogs: dialogsReducer,
featuredSessions: featuredSessionsReducer,
feedback,
filters: filtersReducer,
gallery: galleryReducer,
members: membersReducer,
notificationPermission,
notificationsSubscribers: notificationsSubscribersReducer,
notificationsUsers: notificationsUsersReducer,
partners,
potentialPartners: potentialPartnersReducer,
previousSpeakers: previousSpeakersReducer,
schedule: scheduleReducer,
sessions: sessionsReducer,
snackbars,
speakers: speakersReducer,
subscribed: subscribeReducer,
teams: teamsReducer,
tickets: ticketsReducer,
ui: uiReducer,
updateNotificationsSubscribers: updateNotificationsSubscribersReducer,
updateNotificationsUsers: updateNotificationsUsersReducer,
user: userReducer,
videos: videosReducer,
},
reducer: reducers,
});

export type RootState = ReturnType<typeof store.getState>;
56 changes: 56 additions & 0 deletions src/store/reducers.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,56 @@
import { combineReducers } from '@reduxjs/toolkit';
import { authReducer } from './auth/reducers';
import { blogReducer } from './blog/reducers';
import { dialogsReducer } from './dialogs/reducers';
import { featuredSessionsReducer } from './featured-sessions/reducers';
import feedback from './feedback';
import { filtersReducer } from './filters/reducers';
import { galleryReducer } from './gallery/reducers';
import { membersReducer } from './members/reducers';
import notificationPermission from './notification-permission';
import { notificationsSubscribersReducer } from './notifications-subscribers/reducers';
import { notificationsUsersReducer } from './notifications-users/reducers';
import partners from './partners';
import { potentialPartnersReducer } from './potential-partners/reducers';
import { previousSpeakersReducer } from './previous-speakers/reducers';
import { scheduleReducer } from './schedule/reducers';
import { sessionsReducer } from './sessions/reducers';
import snackbars from './snackbars';
import { speakersReducer } from './speakers/reducers';
import { subscribeReducer } from './subscribe/reducers';
import { teamsReducer } from './teams/reducers';
import { ticketsReducer } from './tickets/reducers';
import { uiReducer } from './ui/reducers';
import { updateNotificationsSubscribersReducer } from './update-notifications-subscribers/reducers';
import { updateNotificationsUsersReducer } from './update-notifications-users/reducers';
import { userReducer } from './user/reducers';
import { videosReducer } from './videos/reducers';

export const reducers = combineReducers({
auth: authReducer,
blog: blogReducer,
dialogs: dialogsReducer,
featuredSessions: featuredSessionsReducer,
feedback,
filters: filtersReducer,
gallery: galleryReducer,
members: membersReducer,
notificationPermission,
notificationsSubscribers: notificationsSubscribersReducer,
notificationsUsers: notificationsUsersReducer,
partners,
potentialPartners: potentialPartnersReducer,
previousSpeakers: previousSpeakersReducer,
schedule: scheduleReducer,
sessions: sessionsReducer,
snackbars,
speakers: speakersReducer,
subscribed: subscribeReducer,
teams: teamsReducer,
tickets: ticketsReducer,
ui: uiReducer,
updateNotificationsSubscribers: updateNotificationsSubscribersReducer,
updateNotificationsUsers: updateNotificationsUsersReducer,
user: userReducer,
videos: videosReducer,
});

0 comments on commit 18141b1

Please sign in to comment.