47:49Confusing CSS behaviors that actually make sense
From the creator
CSS can be infuriating at times. There are some really strange things that it does... BUT a lot of those infuriating things happen for a reason. Once you understand the *why*, not only does it make it less infuriating, but all of CSS just starts to become a bit more predictable and a lot more fun to write. 🔗 Links ✅ Codepen: https://codepen.io/kevinpowell/pen/JjJXMjR ✅ Collapsing margins: https://youtu.be/qKiz9gdJdr8 ⌚ Timestamps 00:00 - Introduction 00:51 - Height as a percentage 03:50 - The space under images (and other replaced elements) 06:46 - Padding and margin top and bottom as a percentage 10:41 - "hack" to boosting specificity #css -- Come hang out with other dev's in my Discord Community 💬 https://discord.gg/nTYCvrK Keep up to date with everything I'm up to ✉ https://www.kevinpowell.co/newsletter Come hang out with me live every Monday on Twitch! 📺 https://www.twitch.tv/kevinpowellcss --- Help support my channel 👨🎓 Get a course: https://www.kevinpowell.co/courses 👕 Buy a shirt: https://teespring.com/stores/making-the-internet-awesome 💖 Support me on Patreon: https://www.patreon.com/kevinpowell --- My editor: VS Code - https://code.visualstudio.com/ --- I'm on some other places on the internet too! If you'd like a behind the scenes and previews of what's coming up on my YouTube channel, make sure to follow me on Instagram and Twitter. Twitter: https://twitter.com/KevinJPowell Codepen: https://codepen.io/kevinpowell/ Github: https://github.com/kevin-p
Published 2021-09-14 · Watch on YouTube ↗
Availability and playback restrictions are controlled by the original channel.





