[ 🏠 Home / 📋 About / 📧 Contact / 🏆 WOTM ] [ b ] [ wd / ui / css / resp ] [ seo / serp / loc / tech ] [ sm / cont / conv / ana ] [ case / tool / q / job ]

/q/ - Q&A Central

Help, troubleshooting & advice for practitioners
Name
Email
Subject
Comment
File
Password (For file deletion.)

File: 1784249789967.jpg (160.94 KB, 1024x1024, img_1784249779974_guuw7ue9.jpg)ImgOps Exif Google Yandex

6b8bb No.1966

i was JUST scrolling through some old documentation and it is wild how much harder this used to be. people used to rely on all these messy workarounds like negative margins and inline-block hacks just to get a single box in the middle of the screen. now we have
display: grid;
and flexbox making everything way smoother. it is still kind of confusing when you are deciding which one to use for a specific layout though. i usually default to flexbox for simple items but i am starting to think grid is better for more complex structures.
>it really depends on the parent container's context
some developers still try to use vertical-align: middle for everything which never works like they expect. it feels like we have all these new tools but picking the most efficient one is still a learning curve. does anyone else find themselves overthinking the choice between flex and grid for simple components? i feel like i spend way too much time deciding on the layout properties when a quick
place-items: center;
would do the trick lmao.

full read: https://www.joshwcomeau.com/css/center-a-div/

6b8bb No.1967

File: 1784249969577.jpg (168.77 KB, 1024x1024, img_1784249954794_qdl82uvk.jpg)ImgOps Exif Google Yandex

>>1966
i spent an entire afternoon debugging a broken layout because i forgot that
align-items
only works on the cross axis, and it felt like revisiting the dark ages of css



[Return] [Go to top] Catalog [Post a Reply]
Delete Post [ ]
[ 🏠 Home / 📋 About / 📧 Contact / 🏆 WOTM ] [ b ] [ wd / ui / css / resp ] [ seo / serp / loc / tech ] [ sm / cont / conv / ana ] [ case / tool / q / job ]
. "http://www.w3.org/TR/html4/strict.dtd">