Skip to content

Commit

Permalink
Fix: rollback to react 18 due to issues with @aldabil/react-scheduler…
Browse files Browse the repository at this point in the history
… issues and react 19
  • Loading branch information
aelassas committed Jan 23, 2025
1 parent 8a4bc86 commit 1229283
Show file tree
Hide file tree
Showing 11 changed files with 205 additions and 280 deletions.
206 changes: 107 additions & 99 deletions backend/package-lock.json

Large diffs are not rendered by default.

20 changes: 10 additions & 10 deletions backend/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -11,24 +11,24 @@
"preview": "vite preview",
"fix": "eslint --fix .",
"lint": "eslint . --ext ts,tsx --report-unused-disable-directives --max-warnings 0",
"ncu": "ncu -u -x typescript,date-fns,eslint,eslint-plugin-react-hooks,eslint-plugin-react-refresh",
"ncu": "ncu -u -x typescript,date-fns,eslint,eslint-plugin-react-hooks,eslint-plugin-react-refresh,react,react-dom,@types/react,@types/react-dom",
"stylelint": "stylelint \"src/**/*.css\"",
"stylelint:fix": "stylelint \"src/**/*.css\" --fix"
},
"dependencies": {
"@aldabil/react-scheduler": "^2.9.5",
"@emotion/react": "^11.14.0",
"@emotion/styled": "^11.14.0",
"@mui/icons-material": "^6.4.0",
"@mui/material": "^6.4.0",
"@mui/icons-material": "^6.4.1",
"@mui/material": "^6.4.1",
"@mui/x-data-grid": "^7.24.0",
"@mui/x-date-pickers": "^7.24.0",
"@types/node": "^22.10.7",
"@types/react": "^19.0.7",
"@types/react-dom": "^19.0.3",
"@types/react": "^18.3.12",
"@types/react-dom": "^18.3.1",
"@types/validator": "^13.12.2",
"@typescript-eslint/eslint-plugin": "^8.20.0",
"@typescript-eslint/parser": "^8.20.0",
"@typescript-eslint/eslint-plugin": "^8.21.0",
"@typescript-eslint/parser": "^8.21.0",
"@vitejs/plugin-react": "^4.3.4",
"axios": "^1.7.9",
"cross-env": "^7.0.3",
Expand All @@ -38,13 +38,13 @@
"eslint-plugin-react-refresh": "^0.4.11",
"history": "^5.3.0",
"localized-strings": "^2.0.3",
"react": "^19.0.0",
"react-dom": "^19.0.0",
"react": "^18.3.1",
"react-dom": "^18.3.1",
"react-router-dom": "^7.1.3",
"react-toastify": "^11.0.3",
"typescript": "^5.2.2",
"validator": "^13.12.0",
"vite": "^6.0.7"
"vite": "^6.0.11"
},
"devDependencies": {
"@babel/plugin-transform-runtime": "^7.25.9",
Expand Down
47 changes: 0 additions & 47 deletions backend/src/components/SuspenseRouter.tsx

This file was deleted.

4 changes: 2 additions & 2 deletions backend/src/context/GlobalContext.tsx
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import React, { ReactNode, createContext, use, useMemo, useState } from 'react'
import React, { ReactNode, createContext, useContext, useMemo, useState } from 'react'

// Create context
export interface GlobalContextType {
Expand All @@ -24,4 +24,4 @@ export const GlobalProvider = ({ children }: GlobalProviderProps) => {

// Create a custom hook to access context
// eslint-disable-next-line react-refresh/only-export-components
export const useGlobalContext = () => use(GlobalContext)
export const useGlobalContext = () => useContext(GlobalContext)
98 changes: 43 additions & 55 deletions frontend/package-lock.json

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

13 changes: 6 additions & 7 deletions frontend/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,12 +13,11 @@
"preview": "vite preview",
"fix": "eslint --fix .",
"lint": "eslint . --ext ts,tsx --report-unused-disable-directives --max-warnings 0",
"ncu": "ncu -u -x typescript,date-fns,eslint,eslint-plugin-react-hooks,eslint-plugin-react-refresh",
"ncu": "ncu -u -x typescript,date-fns,eslint,eslint-plugin-react-hooks,eslint-plugin-react-refresh,react,react-dom,@types/react,@types/react-dom,react-leaflet",
"stylelint": "stylelint \"src/**/*.css\"",
"stylelint:fix": "stylelint \"src/**/*.css\" --fix"
},
"dependencies": {
"@aldabil/react-scheduler": "^2.9.5",
"@emotion/react": "^11.14.0",
"@emotion/styled": "^11.14.0",
"@mui/icons-material": "^6.4.0",
Expand All @@ -31,8 +30,8 @@
"@types/leaflet-boundary-canvas": "^1.0.3",
"@types/node": "^22.10.7",
"@types/nprogress": "^0.2.3",
"@types/react": "^19.0.7",
"@types/react-dom": "^19.0.3",
"@types/react": "^18.3.12",
"@types/react-dom": "^18.3.1",
"@types/react-recaptcha-v3": "^1.1.5",
"@types/react-slick": "^0.23.13",
"@types/validator": "^13.12.2",
Expand All @@ -51,11 +50,11 @@
"leaflet-boundary-canvas": "^1.0.0",
"localized-strings": "^2.0.3",
"nprogress": "^0.2.0",
"react": "^19.0.0",
"react": "^18.3.1",
"react-circle-flags": "^0.0.23",
"react-dom": "^19.0.0",
"react-dom": "^18.3.1",
"react-ga4": "^2.1.0",
"react-leaflet": "^5.0.0",
"react-leaflet": "^4.2.1",
"react-router-dom": "^7.1.3",
"react-slick": "^0.30.3",
"react-toastify": "^11.0.3",
Expand Down
47 changes: 0 additions & 47 deletions frontend/src/components/SuspenseRouter.tsx

This file was deleted.

Loading

0 comments on commit 1229283

Please sign in to comment.