Skip to content

Modify wins.js to accept GitHub and LinkedIn usernames and construct URLs#8613

Open
lc1715 wants to merge 1 commit intohackforla:gh-pagesfrom
lc1715:add-github-linkedin-usernames-5470
Open

Modify wins.js to accept GitHub and LinkedIn usernames and construct URLs#8613
lc1715 wants to merge 1 commit intohackforla:gh-pagesfrom
lc1715:add-github-linkedin-usernames-5470

Conversation

@lc1715
Copy link
Copy Markdown
Member

@lc1715 lc1715 commented Apr 21, 2026

Fixes #5470

What changes did you make?

  • Updated the code in assets/wins.js so that if the existing fields Github URL (optional) and Linkedin URL (optional) are blank, the code will reference the new fields GitHub Handle and LinkedIn Name and will construct the appropriate URLs.

Why did you make the changes (we will use this info to test)?

  • We need to modify wins.js so that if the existing GitHub/LinkedIn fields (which contain URLs) are not populated, the code will use the new fields GitHub Handle and LinkedIn Name and reconstruct the appropriate URLs.

CodeQL Alerts

After the PR has been submitted and the resulting GitHub actions/checks have been completed, developers should check the PR for CodeQL alert annotations.

Check the PR's comments. If present on your PR, the CodeQL alert looks similar as shown

Screenshot 2024-10-28 154514

Please let us know that you have checked for CodeQL alerts. Please do not dismiss alerts.

  • I have checked this PR for CodeQL alerts and none were found.
  • I found CodeQL alert(s), and (select one):
    • I have resolved the CodeQL alert(s) as noted
    • I believe the CodeQL alert(s) is a false positive (Merge Team will evaluate)
    • I have followed the Instructions below, but I am still stuck (Merge Team will evaluate)
Instructions for resolving CodeQL alerts

If CodeQL alert/annotations appear, refer to How to Resolve CodeQL alerts.

In general, CodeQL alerts should be resolved prior to PR reviews and merging

Screenshots of Proposed Changes To The Website (if any, please do not include screenshots of code changes)

  • No visual changes to the website

@github-actions
Copy link
Copy Markdown

Want to review this pull request? Take a look at this documentation for a step by step guide!


From your project repository, check out a new branch and test the changes.

git checkout -b lc1715-add-github-linkedin-usernames-5470 gh-pages
git pull https://github.com/lc1715/website.git add-github-linkedin-usernames-5470

@github-actions github-actions Bot added role: front end Tasks for front end developers Complexity: Medium P-Feature: Wins Page https://www.hackforla.org/wins/ size: 1pt Can be done in 4-6 hours labels Apr 21, 2026
@santi-jose santi-jose self-requested a review April 22, 2026 01:25
@santi-jose
Copy link
Copy Markdown
Member

Review ETA: 6PM 4/24/2026
Availability: 6 - 8PM Monday - Friday

@mocodesss
Copy link
Copy Markdown
Member

Review ETA: EOD 4/22/2026
Availability: Tues, Thurs, Fri after 4 pm

Copy link
Copy Markdown
Member

@santi-jose santi-jose left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi Lisa,

Nice work on this. Using the GitHub Handle and LinkedIn Name properties to construct the URL values in the main function keeps the code simple and avoids duplicating conditional logic at the point of use. That made the implementation feel really clean and easy to follow.

I tested this by updating a few entries in _wins-data.json with GitHub Handle and LinkedIn Name values, and confirmed that the URLs are constructed correctly when the original URL fields are empty.

I was curious how you tested this on your end since the changes aren't directly visible in the UI and rely on data in the JSON file. I'd be interested to hear your approach there.

No changes requested from my side, happy to approve.

@lc1715
Copy link
Copy Markdown
Member Author

lc1715 commented Apr 23, 2026

Hi Jose!

Yes, I also tested this by updating the GitHub Handle and LinkedIn Name values in the _wins-data.json file. I ran Docker to view the changes in the browser and console.log cardData inside of the main function to see the newly constructed URLs.

@santi-jose
Copy link
Copy Markdown
Member

Awesome, sounds like we're on the same page. Nice work Lisa!

@lc1715
Copy link
Copy Markdown
Member Author

lc1715 commented Apr 24, 2026

Thanks!

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

Labels

Complexity: Medium P-Feature: Wins Page https://www.hackforla.org/wins/ role: front end Tasks for front end developers size: 1pt Can be done in 4-6 hours

Projects

Status: PR Needs review

Development

Successfully merging this pull request may close these issues.

Modify wins.js to accept GitHub and LinkedIn usernames or complete URLs

3 participants