FaberBenjamin
@FaberBenjaminAll comments
- @ivseasonsSubmitted almost 2 years ago@FaberBenjaminPosted almost 2 years ago
Hi,
You can fix your mini-bug of images not appearing by modifying your
src
like this: "./images/" instead of "/images/".Other than this it is a wonderful work! :D
Marked as helpful0 - @dvcode01Submitted almost 2 years ago
Hello everyone who is viewing this message, as you can see this is the project I did today. I hope you like it and any comments you want to make me, you are free to do so.
@FaberBenjaminPosted almost 2 years agoWow, actually amazing. I did this not so long ago though I think yours is better in the UI part. Just one notice: The number of people couldn't be zero - that's very nice. First, I made a mistake and made it possible to be zero in my project. Turns out, I learned what
value = infinity
meas in JS. Guess we learn something everyday.But you can still type negative values in your calculator (-1, -10). Its just a small bug but this code really deserves to be perfect because its so nice.
Hope to see more of your works!
Marked as helpful1 - @vishanthan8055Submitted almost 2 years ago
Still confusing in centering and sizing the div elements. Anyone help me?
@FaberBenjaminPosted almost 2 years agoNormally, if you have a
div
element in yourbody
and nothing else, thebody
will adjust its size to its content[children]. (simplified.: the body will have the same height and width as the element inside, even if it smaller then the screen-size. You can check it in the dev-tools to see if your actual body is smaller than your visual screen)To overcome this, you can set the body height manually with
height
ormin-height
. The latter is more preferred because the first one can causeoverflow
issues. As mentioned before you can also set thebody
toflex
and adjust accordingly or play around with thedisplay: inline-block
orgrid
selectors.Actually it is more hard to grasp than it seems (even I tend to be "lazy" about it from time to time.) If you need more help, you can find me on github/twitter so we could talk more about it.
Your project looks nice btw. Keep going on!
Marked as helpful1 - @ikennarichardSubmitted almost 2 years ago
Hello Friends, please can you give me a review for my project, and could you help me understand preprocessors because I'm not quite sure how their use, it feels like writing CSS in another language, please what's its actual use. THANKS A LOT
@FaberBenjaminPosted almost 2 years agoCSS preprocessors indeed are somewhat a different language. Their goal is to create the actual .css file for you. If you use Sass for example - you don't actually use the .scss file in which you write your designs. Another file (.css) is created by Sass which will be used. There are some reasons to use preprocessors.
In Sass for example you can create custom elements (Mixins) which you can use as much and anywhere in your code as you would like (you don't have to manually type is 100 times).
Also in Sass you can use Variables so you can write your own custom colors and others etc. Tailwind makes it very fast to create styles.
Styled Components lets you write CSS in your JavaScript file (very good for React for ex.) But, the main reason for people to use preprocessors is that is makes your final CSS file consistent. Imagine a company where 50 people write in the .css in a style they wish. Would be kinda chaotic. So many companies use preprocessors because of this.
Hope this was helpful and your Advice generator looks awesome.
Marked as helpful1 - @AhmedEssam01Submitted almost 2 years ago@FaberBenjaminPosted almost 2 years ago
Hi,
If you would like to make a perfectly circular element you can set the
border-radius
to 50% (actually there is no need to set it to 100) and give the element the samewidth
andheight
value. You can define both of them to be the same, or just one of them while using theaspect-ratio 1/1
attribute. Other than this your code looks amazing.Congratulations :D !
0