@krebeDev
Submitted
This is my first major attempt at React. I'll appreciate tips on how to improve my code. Thanks in advance.
Looking to hire developers?
@krebeDev
@krebeDev
Submitted
This is my first major attempt at React. I'll appreciate tips on how to improve my code. Thanks in advance.
@krebeDev
Posted
I appreciate your feedback @mattstuddert.
As a beginner, working with React was quite tough, but exciting nonetheless.
e.currentTarget.id
to userChoice.name
will directly mutate the userChoice
object in state
, because I started off by cloning userChoice
and houseChoice
like so:handlePick = (e) => {
const userChoice = {...this.state.userChoice};
const houseChoice = {...this.state.houseChoice};
// Other code lines go here
}
Do I have to clone/setState for each key : value pair in this instance?
I've started learning about hooks, and definitely will apply them once I get the hang of it.
Starter
component too. I'll fix them.@krebeDev
Submitted
I've had to use two empty div
s to display the curly background patterns in the intro section. I feel this approach is not effective. Any ideas on a better way to achieve the design that's in line with best design practices? You're welcome.
@krebeDev
Posted
Thanks for the feedback @mattstuddert. I didn't know I could use url()
as content
for ::before
and ::after
pseudo-elements until today. I'll definitely give it a try.
@confusedDip
Submitted
Please share your feedback!
@krebeDev
Posted
The design is great on desktop/large screens. I suggest you include media queries by introducing different breakpoints/CSS rules to make it responsive in smaller viewports.
@EvonuX
Submitted
Been a while since I've made anything in React, also my first project using hooks! Let me know how if you like it and if I missed something :)
@krebeDev
Posted
I see nothing missing :). Great job you've done here!
@faheem102
Submitted
hej this is my solution as a beginner. i do not know how to fill logo color into white. can some one please explain to me with some easy method to it. thank you
@krebeDev
Posted
Hey @faheem102,
Great work on this challenge. To change the logo colour, one way is to load it directly as svg
element instead of using img
tag. Then change the fill color of the svg
to white inside the svg
style definition.
@vongphakdy
Submitted
I have 2 error cases for email validation; the first is an empty field, second is an invalid email address. Both cases should activate the error message and icon, however only this only applies to the first case. When entering an invalid input, the form reveals a prompt rather than my coded error message/icon. I'm new to JS so I appreciate any input
@krebeDev
Posted
Hello @vongphakdy,
Great job on this challenge. Your error message is not being activated because HTML5 form
comes with built-in form validation. To deactivate this default behaviour and ensure your JavaScript code is triggered, add a novalidate
attribute on the form element. In your case, your code will be like so <form novalidate class="main-form">
.
Also, your JS form validation code should be enhanced to accommodate other use cases. For example, if a user enters a correct email after a wrong attempt, the error message should be discarded.
@DanielGibsonOrchid
Submitted
Feedback is always appreciated! Had great fun making this app, especially going back to basics with vanilla JS.
@krebeDev
Posted
Wow!!! Great work Daniel. I personally have been battling with this challenge for some days now. Your code is clean and comprehensible. I have no improvements to recommend. Great job.
Your feedback is very very important to me and it's appreciated, Thanks for stopping by.
@krebeDev
Posted
I checked in. My observations are the same issues being addressed by @Mattstuddert, particularly the breakpoints. You can improve in those areas.
@chadrack
Submitted
Hi! I'm new at coding if you have any feedback to help me improve. thank you for your time.
@krebeDev
Posted
I also noticed the link to your live site is broken.
@chadrack
Submitted
Hi! I'm new at coding if you have any feedback to help me improve. thank you for your time.
@krebeDev
Posted
Hi Chadrack, great work! Do check your page's Report and fix the accessibility and validation issues. I can help if you need more clarifications on these.
@matejkubicek
Submitted
I'm newbie in front-end development and I know, that my workflow is little bit complicated for this small project, but I trying to learn frontend technologies and tools more comprehensively.
Please leave me a feedback about my code and used workflow. Thx
@krebeDev
Posted
Looks good. But do check the HTML validation report on your solution. The roles
you specified in your markup are unnecessary since you already used the appropriate HTML5 semantic elements.
@TheInstantiator
Submitted
First time I have tried to do anything after taking a course on udemy. Let me know how I did and what I could do better.
Thanks
@krebeDev
Posted
Your work is clean and beautiful. However, in addition to the HTML5 semantic elements already suggested by DJH-dev, you should have used tags like headings (h1,..h6) and <p> for accessibility.