|
|
|
|
|
by Philip-J-Fry
1739 days ago
|
|
CSS doesn't have to be annoying or boring. Understand the Box Model https://developer.mozilla.org/en-US/docs/Learn/CSS/Building_... I find that a lot of front end developers don't really understand the box model and everything they do is just learned patterns. Once you understand how things are laid out then it becomes so much more fun and easy. Now the hard part is the actual design but I wouldn't say that's your job as a developer unless you want to be a designer. Some of the funnest front end work I've done is taking someone's Sketch file and implementing it in CSS. Seeing things come together into an interactive web page. If you don't want to write CSS or do any design then use a component library like bootstrap, tailwind, etc. Especially for an MVP. But if you want something more bespoke then get someone to design a web page with documentation of all the sizing like font sizes, margins, padding etc. And learn to implement that, it's a lot easier than many people think. Especially now that you don't need to care about IE. |
|
* The article starts by saying there are two types of boxes. OK. Boxes have an inner and an outer display type. Already confused. Is this in addition to the two previously mentioned types? Does a box have the following: (type, inner display type, outer display type)? "First, we will explain what we mean by block box and inline box". Err what, you haven't mentioned those yet. Are they a type, an inner display type, an outer display type, or all of the above? "If a box has an outer display type of block, it will behave in the following ways". So block/inline are types of inner/outer display types? What is going on?
* Why does there need to be two distinct types of element, which seem to be randomly applied to different elements (divs are block, spans are inline)?
* Why are they called "block" and "inline" when those words don't seem to relate to their behaviour at all?
* Why does inline silently ignore width and height?
* What is an "inline direction"
* What does breaking onto a newline mean, and why do I care? Why not show a diagram?
Then my ADHD brain loses interest and concedes I will never understand.