Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

#187790848 Set up Axios interceptors for Network errors, 401 Errors and redirections #20

Closed
wants to merge 1 commit into from

Conversation

Jovz19200
Copy link
Collaborator

What does the PR do?

Axios interceptors are implemented to intercept the following situations:

  • Network Error: It triggers a popup concerning the Issue
  • 401 Error or unAuthorized: redirected to try and login !!
  • Authenticated users redirected to landing when they try logging in again !!

How to test this manualy

  • after cloning and installing the deps
  • RUN npm run dev to start the FR server
  • try logging In, and retry logging in after a successful login which will redirect you to landing Page.
  • try cutting the connection to server to cause Network Error and see the interception when trying to utilize axios.
  • An Unauthanticated activity is redirected to login?

Implementation

Uploading Screenshot 2024-07-08 at 06.03.07.png…
Uploading Screenshot 2024-07-08 at 06.03.27.png…

Copy link

vercel bot commented Jul 8, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
eagles-ec-fe ✅ Ready (Inspect) Visit Preview 💬 Add feedback Jul 12, 2024 1:57pm

Copy link

codeclimate bot commented Jul 12, 2024

Code Climate has analyzed commit b8a85e0 and detected 0 issues on this pull request.

View more on Code Climate.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant