Skip to content
This repository was archived by the owner on Sep 13, 2022. It is now read-only.

Zipcode/City Search React Lab_Edgardo/Silu#93

Open
sonyaw612 wants to merge 14 commits intoCUNYTechPrep:masterfrom
sonyaw612:master
Open

Zipcode/City Search React Lab_Edgardo/Silu#93
sonyaw612 wants to merge 14 commits intoCUNYTechPrep:masterfrom
sonyaw612:master

Conversation

@sonyaw612
Copy link

What type of PR is this? (check all applicable)

  • ♻️ Refactor
  • ✨ Feature
  • 🐛 Bug Fix
  • 👷 Optimization
  • 📝 Documentation Update
  • 🔖 Release
  • 🚩 Other

Description

This PR [adds/removes/fixes/replaces] this [feature/bug/etc].

Related Tickets & Documents

Mobile & Desktop Screenshots/Recordings

Added tests?

  • 👍 yes
  • 🙅 no, because they aren't needed
  • 🙋 no, because I need help

Added to documentation?

  • 📜 readme
  • 📜 contributing.md
  • 📓 docs
  • 📕 storybook
  • 🙅 no documentation needed

[optional] Are there any post-deployment tasks we need to perform?

[optional] What gif best describes this PR or how it makes you feel?

@sonyaw612 sonyaw612 changed the title Part 1 Complete, Edgardo/Silu Zipcode/City Search React Lab_Edgardo/Silu Oct 9, 2021
<h3>Zip Codes for {this.state.cityName}: </h3>
{/* { console.log(this.state.zipcodes)} */}
<div>
{ this.state.zipcodes.forEach((element) => {
Copy link
Member

Choose a reason for hiding this comment

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

@sonyaw612 I didn't catch this earlier, but the issue is the .forEach() method. The forEach method always returns undefined after all processing is done. What you need here is to replace it with the .map() method which transforms the entire array into a new array based on your callback.

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants

Comments