Live data from Hacker News

Things I wish I’d known about CSS

cssfordesigners.com

111–120 of 340 posts

Re: Things I wish I’d known about CSS

#111

I wish the author had gone a bit further into em vs rem. I'm reading other articles on the topic but they're simply technical explanations and I'm still not clear on what features of the page are best designed using em or rem.

Just to mess with your mind: in media queries and in the root element’s font-size declaration, em and rem mean the same thing, being the browser’s default font size, which is 16px in most browsers by default, but customisable in some browsers and different by default in some environments (e.g. I seem to recall Kindle using 19px). I call this unit the “browser em”, or bem. No one else really talks about it. One thing I haven’t investigated and probably should: does this unit depend on the language the document is specified in? (Because you can define different default fonts and sizes for different languages in at least Firefox.)

Re: Things I wish I’d known about CSS

#113
post #36

Earlier quoted context omitted.

Six figures? In the US? Sometimes I wonder why companies even pay developers so much in the US. I'm a specialised medical embedded software developer in the UK and I'm not even halfway to six figures, and will likely never hit it. It astounds me that companies don't hire twice as many non-US developers for the same price and get more work for their money. Note, I'm not talking about outsourcing to the absolute cheape…

The US salaries in IT are huge, but you need to take into account that they have to pay a lot to have a quality of life comparable to what a minimum wage worker is getting in west Europe. If you have a few kids, I would bet you are not that bad in UK with one fewer digit.

In the United States, you can spend 6k on health insurance and 12k out of pocket for unlimited family health care.

So as long as a US job pays 18k more, it's pretty similar.

People talk about vacation, but my job pays so much I'll take months off between contracts. (Engineering)

Also it's hard to compare lifestyles in the US vs Europe. Homes in the US are gigantic, often newish, and have Air Conditioning. Cars in the United States are more feature rich and have higher safety standards (when I was an airbag engineer in 2015)

Re: Things I wish I’d known about CSS

#114
> If your CSS reset doesn’t include this already, I’d suggest adding the following rule: ...

If I'm trying to build a site design from scratch (rather than using Bootstrap or similar), is a CSS Reset a good place to start? Is there one in particular that's recommended?

Re: Things I wish I’d known about CSS

#115
post #92
post #36

Earlier quoted context omitted.

Six figures? In the US? Sometimes I wonder why companies even pay developers so much in the US. I'm a specialised medical embedded software developer in the UK and I'm not even halfway to six figures, and will likely never hit it. It astounds me that companies don't hire twice as many non-US developers for the same price and get more work for their money. Note, I'm not talking about outsourcing to the absolute cheape…

> Sometimes I wonder why companies even pay developers so much in the US. Presenteeism. The office "has to" be in Silicon Valley. The employees "have to" be in that office, in an open plan, so the manager can physically see them working. Therefore they have to be paid huge wages to compete against the other employers doing the same.

Maybe it's a stereotype, but my Engineering counterparts in Europe were apathetic/lazy.

Might have been a few bad Apples.

Re: Things I wish I’d known about CSS

#116

It feels like HTML and CSS could be useful for print layout, but I’ve rarely seen a high quality PDF renderer. I know Atom’s markdown preview uses headless chrome under the hood. These are hugely heavyweight tools but the output is very high quality. Are there any other recommended tools for going an HTML route, for typesetting? I’d much rather design pages that way than use InDesign, PDF scripting, or TeX.

I have been using Python with Jinja2 templates and Weasyprint[1] for PDF creation for a side project of mine. The libary does have its css limitations but the PDFs it produces look good enough for me. [1] https://weasyprint.org/

Yes, I was going to recommend WeasyPrint as well.

Re: Things I wish I’d known about CSS

#117
post #114

> If your CSS reset doesn’t include this already, I’d suggest adding the following rule: ... If I'm trying to build a site design from scratch (rather than using Bootstrap or similar), is a CSS Reset a good place to start? Is there one in particular that's recommended?

It can be a very helpful start, but I'd review to make sure you're learning from it as well, rather than building onto something that could set you up for confusion later if you end up working without it. Here's one that's popular, lightweight, and helpful in my experience:

https://necolas.github.io/normalize.css/

Re: Things I wish I’d known about CSS

#118
post #94

A little secret opinion of mine is that I think the global usage of rem instead of px is a fad. The only real argument I've heard is that the mobile devices have their own definition of it, and will thus optimize in their own way, but then again I see that benefit as being nearly non-existant and definitely not demonstrated.

strongly agree. this article sums the current state up perfectly: https://medium.com/hackernoon/rems-and-ems-and-why-you-proba...

Re: Things I wish I’d known about CSS

#119
post #98

That is really useful. I have been writing small html front-ends since 2008-09. HTML5,CSS3 made many things easier like gradients, Round borders, and many things that now developer do takes as granted. I clearly remember, how boring and frustrating it was to slice borders and corners from photoshop psd. CSS3 and HTML5 made many good changes, but new css feature like grid, Flex-box all are still confusing. I have to l…

Have you ever taken some deliberate time to really „play“ with those? My recommendation: take a calculator or spreadsheet and start with some simple cases and build up your knowledge in a exploratory manner. A few hours, a session for each feature (flex, grid). Its not only fun but also really helpful!

yes, I really did play with it multiple times. Its just sometimes I require more revisions.

Re: Things I wish I’d known about CSS

#120
post #36
post #31

Yikes. I've been earning 6 figures as of about two years ago doing mostly HTML and CSS UI design for a bank. And I still did not know about many of these! I guess they are things I wish I'd known about CSS! Better late than never I guess.

Six figures? In the US? Sometimes I wonder why companies even pay developers so much in the US. I'm a specialised medical embedded software developer in the UK and I'm not even halfway to six figures, and will likely never hit it. It astounds me that companies don't hire twice as many non-US developers for the same price and get more work for their money. Note, I'm not talking about outsourcing to the absolute cheape…

I think the important bit of info is that they work for a bank, not that they write CSS.

If I look at the equivalent compensation for people who work for me, the vast majority of developers in the UK and US earn > $100k. Like for like the US employees earn more but that's almost wholly swallowed up in other costs (basically healthcare and our US healthcare plan isn't particularly bad).

And the FAANGs and hedge funds, in my experience, have a reasonably similar dynamic.

The simple fact is that we generally don't hire for PL knowledge except in very specific circumstances (KDB for example). If all we wanted was a coder, there are much more cost effective options than hiring someone, regardless of location.

Post reply on HN