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

Protected page fix #1

Merged
merged 3 commits into from
Jul 8, 2020
Merged

Protected page fix #1

merged 3 commits into from
Jul 8, 2020

Conversation

meenakshi-dhanani
Copy link

Description

Type of Change:

  • Code

Code/Quality Assurance Only

  • Fixes routing to components using react-router-dom and the react-bootstrap NavLink: The Nav.Link of the react-bootstrap when given href reloaded the entire app. With React we are building a single page app. If we do a full reload on every link change, everything gets reset. The context, state, etc. Hence, I switched the href to "to". It helps navigate to the appropriate component without a full reload.
  • Removed the use of underscore library. There were comparisons checking !isEmpty(something) which essentially means check if something is present. So replaced that and then underscore was not needed.

Checklist:

  • My PR follows the style guidelines of this project
  • I have performed a self-review of my own code or materials
  • I have commented my code or provided relevant documentation, particularly in hard-to-understand areas
  • I have made corresponding changes to the documentation
  • Any dependent changes have been merged

Code/Quality Assurance Only

  • My changes generate no new warnings
  • My PR currently breaks something (fix or feature that would cause existing functionality to not work as expected)
  • I have added tests that prove my fix is effective or that my feature works
  • New and existing unit tests pass locally with my changes
  • Any dependent changes have been published in downstream modules

Please note: I have also removed the withRouter, after removing it also things are working so adding it didn't make a difference. Hence removed it.

@mtreacy002 mtreacy002 merged commit 02d00dd into mtreacy002:issue#30-protected-page-v3 Jul 8, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants