Sticky Footer in React (Best Solution)

preview_player
Показать описание
Hi, I'm Wesley. I'm a brand ambassador for Kinde (paid sponsorship). I'll help you master the latest tech here:

👉 Discord: all my courses have a private Discord where I actively participate

0:00 Intro
0:10 Best solution in 2022 (Flexbox)
4:00 Worse solution 1 (position: absolute)
4:37 Worse solution 2 (CSS grid)
5:05 Worse solution 3 (min-height calc() for content)
5:56 Fixed footer

#stickyfooter #cssfooter #reactfooter #webdevelopment #coding #programming
Рекомендации по теме
Комментарии
Автор

These solutions seem simple, but take so darn long to solve/figure out! Thanks for sharing 🙏

arhabersham
Автор

Normally I don’t comment… but this time I wanna say just „thank you“ for the clean solution and the calm, simple and good explanation of the mechanism behind it. 👍

gnuf
Автор

thank you so much i spent hours on this but you explained it really well enough for me to understand and implement it in my website

dgeneral
Автор

Thank you Wesley, you've made my day!. Subscribed.

aNDy-qhem
Автор

bro, the satisfaction I felt when I set margin-top: auto; and that footer stuck to the botton was indescribable. Thank you!! I had solved this issue in another way but when the view port was tiny the footer would take the entire page because the position was fixed.

prpunk
Автор

You saved me thanks.. I'm starting with React and couldn't make and didn't think it was that easy, I did all these mistakes except for calc() and nothing worked, then tried the first one and worked just fine.

xandygameryt
Автор

THANK YOU SO MUCH, I love that u actually explained the fundamentals behind it, the most important aspects were:
margin-top: auto
and getting the parent element to have flexbox
Ty sir!!

juanhedderich
Автор

Wow the only video that actually made sense and worked. Thank you!

armenn
Автор

Thank you!!! ❤
Love your videos, very appreciative!

mister-bham
Автор

Thank you so much... most efficient solution ever!!

srinivasnahak
Автор

This worked perfectly for me! If you're using Tailwind to build a React app: set the parent div to `className="min-h-screen flex flex-col"` and your footer div to `className="mt-auto"`. Does the same thing as doing this in standard CSS.

colinmarshall
Автор

thanks, brother you really helped me.

utkarshsharma
Автор

wow! been looking this solution for months!! got lots of ways but all of them were horrible! Thank u !

kfirlankry
Автор

Thank you, I wish I found this video earlier, great explanation and solves the problem perfectly.

Martin-qymm
Автор

I was trying to keep any html out of my app jsx file but it worked out fine once all of the CSS was situated. I just had to delete the text-align:center, because it shifted everything on the page that I didn't want centered. Thanks for the tutorial!

Harpie.
Автор

Thank you so much ! Please continue to amaze this world

funckialexjoly
Автор

thank you for in-depth explanation and clean solution! 😀

stanislavus
Автор

it's 3:30 Am in India And i was searching for the solution of my problem And i found Your video, Thanks A Lot sir...!! 🙏🏻🙏🏻🙏🏻

thevishingh
Автор

clearly, the best solution of course! Thanks, worked for me!!

GabrielLima-sgpn
Автор

What a great and concise video this is! Thank you!

Deric_Rocks