-
Notifications
You must be signed in to change notification settings - Fork 29
Test for getCookie and minor code improvements #224
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
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please add jsdom to the dev dependencies and get rid of white space only lines.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good, although I'm confused by the seemingly unrelated changes in the .env.example
file. Can you explain why you made those changes? Also, linting is failing.
.env.example
Outdated
|
||
|
||
PUBLIC_NAV_BAR_LINKS={"Home": "/","About": "/about","Contact": "/contact","Fares & Tolls": "/fares-and-tolls"} | ||
PUBLIC_NAV_BAR_LINKS='{"Home": "/","About": "/about","Contact": "/contact","Fares & Tolls": "/fares-and-tolls"}' |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
what prompted this change?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yeah well the change is not very related to what I was doing mainly but the syntax of the value of the variable seemed to be incorrect. The variable attempted to directly store a dictionary which i thought was not standard practice. If this change was not ideal however please advise me on how to go about it next time.
Thank You.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
please undo this change.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
revert the changes to .env.example
please
.env.example
Outdated
|
||
|
||
PUBLIC_NAV_BAR_LINKS={"Home": "/","About": "/about","Contact": "/contact","Fares & Tolls": "/fares-and-tolls"} | ||
PUBLIC_NAV_BAR_LINKS='{"Home": "/","About": "/about","Contact": "/contact","Fares & Tolls": "/fares-and-tolls"}' |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
please undo this change.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
👍 but please review my feedback for future changes.
PUBLIC_ANALYTICS_DOMAIN="" | ||
PUBLIC_ANALYTICS_ENABLED=true | ||
PUBLIC_ANALYTICS_API_HOS="" | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
In the future, please be sure to avoid including extra whitespace like this in a file that you've reverted your other changes in.
This request addresses two key improvements:
Added Test Coverage for
getCookie
:getCookie
function inlib/utils/user.js
.Improved Code Clarity in
lib/utils/user.js
: