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

project-music-releases-vite-Emelie_Nyberg_Kedert #98

Open
wants to merge 4 commits into
base: main
Choose a base branch
from

Conversation

EmelieNyberg
Copy link

@JennieDalgren JennieDalgren self-assigned this Oct 17, 2024
Copy link

@JennieDalgren JennieDalgren left a comment

Choose a reason for hiding this comment

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

Great job with this project!
You've met all requirements.

You’ve done a great job breaking the logic into smaller components (AlbumCover, AlbumName, ArtistName etc), each handling a specific part of the album's display. This improves code readability and maintainability.

Gotchas for next time:

  1. Destructuring Props:
    Instead of passing props.albumcard in multiple places, you could destructure the props at the beginning of the function for cleaner code. For example:

const { albumcard } = props;
Then, you can directly use albumcard inside the JSX.

  1. Passing Specific Props:
    Instead of passing the entire albumcard object to each child component, consider passing only the specific pieces of data that each child component needs. For instance, AlbumCover only needs the cover image URL, AlbumName only needs the album's name, and ArtistName needs the list of artists. This will make your components more modular and reusable.
<AlbumCover coverImage={albumcard.image} />
<AlbumName name={albumcard.name} />
<ArtistName artists={albumcard.artists} />

Keep up the good work

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