Skip to content

Conversation

@sandrahagevall
Copy link

Copy link

@Appilistus Appilistus left a comment

Choose a reason for hiding this comment

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

You have done such a great job as always!! The site looks good on every device, and you got high scores on both lighthouse and WAVE! The code and component structure is clean and easy to follow, also the names of components are easy to understand.
I added a few comments on your code, hope it helps ;)

Well done!👏🏻

Choose a reason for hiding this comment

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

You look very confident and professional! Love the picture🤩🙌🏻

Choose a reason for hiding this comment

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

Clean and well structured App.jsx! I learned from your code that having

element is good practice for SEO, accessibility etc. 💫 Well done!

@@ -0,0 +1,44 @@
import styled from "styled-components"

export const StyledButton = styled.button`

Choose a reason for hiding this comment

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

Do you use outside of this component? Maybe no need to export if it's local? :)

Also, I would recommend to style instead of . It's better for accessibility💡 I write more about this in the projectCard.jsx file!

<h3>{title}</h3>
<p>{description}</p>
{link ? (
<a href={link} target="_blank" rel="noopener noreferrer">

Choose a reason for hiding this comment

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

screen shot 2

The same thing as the projectCard😬

Comment on lines 8 to 11
background-color: ${({ theme }) => theme.colors.primary};
color: ${({ theme }) => theme.colors.secondary};
padding: 0 0 5rem;
width: 100%;

Choose a reason for hiding this comment

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

Add indentation :)

Comment on lines 7 to 10
background-color: ${({ theme }) => theme.colors.primary};
color: ${({ theme }) => theme.colors.secondary};
padding: 0 0 5rem;
width: 100%;

Choose a reason for hiding this comment

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

Add indentation :)

Choose a reason for hiding this comment

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

I see you are using {theme} everywhere - that's great! I should also start using it...

src/index.css Outdated

Choose a reason for hiding this comment

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

Maybe you can remove everything if you don't use them?😄

<p className="date">{date}</p>
<h3>{title}</h3>
<p>{description}</p>
{link ? (
Copy link

Choose a reason for hiding this comment

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

You are already doing this link check within the Button component :)

{link ? (
<Button as="a" href={link} target="_blank" rel="noopener noreferrer" icon="/link.svg">Read article</Button>
) : (
<Button icon="/link.svg">Read article</Button>
Copy link

Choose a reason for hiding this comment

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

What does this do when there is no link?

Copy link
Author

Choose a reason for hiding this comment

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

At the moment, the button has no action. I kept it in the UI to follow the Figma design even when no link is available. And I wrote it like this since I was planning to add articles later on, and then the button will behave as intended.

<p>Lorem ipsum dolor sit amet consectetur adipisicing elit. Voluptatem, laborum! Maxime animi nostrum facilis distinctio neque labore consectetur beatae eum ipsum excepturi voluptatum, dicta repellendus incidunt fugiat, consequatur rem aperiam.</p>
<ThemeProvider theme={theme}>
<GlobalStyle />
<a href="#main" className="skip-link">Skip to main content</a>
Copy link

Choose a reason for hiding this comment

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

Nice that you include a "skip to content" link!


<Content $position={position}>
<Tags>
{tags && tags.map((tag, i) => (
Copy link

Choose a reason for hiding this comment

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

A tip! You can make use of optional chaining here instead of checking if the tags are defined first:
tags?.map(...)

Copy link

@Npahlfer Npahlfer left a comment

Choose a reason for hiding this comment

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

Solid use of theme and very easy to follow and you are even using exports in index files! Really nice 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.

3 participants