2 years into web dev (with 20 years of other software dev experience) and I’m rolling my eyes with all this. OK, sure. And I’m exhausted in myself at reaching for frameworks (I’m working on being better) but the fetish around avoiding JavaScript is silly. CSS is amazing, learning how to use selectors better is definitely on my list, but that is not an interview question of any substance.
I agree - it’s like a fun code-golf challenge in that you end up with awful, write-only code but you may well end up with a deeper understanding after solving it. It’s for circumstances almost opposite to an interview.
The proposed solutions don’t even work - for example the tan is only meant to display once per letter.
The actual question does at least ask when it’s JS suitable and when isn’t it - for example it’s irritating to have to wait for a page to init just to be able to access a drop-down menu (hint: use active in CSS instead of a JS toggle).
2 years into web dev (with 20 years of other software dev experience) and I’m rolling my eyes with all this. OK, sure. And I’m exhausted in myself at reaching for frameworks (I’m working on being better) but the fetish around avoiding JavaScript is silly. CSS is amazing, learning how to use selectors better is definitely on my list, but that is not an interview question of any substance.
I agree - it’s like a fun code-golf challenge in that you end up with awful, write-only code but you may well end up with a deeper understanding after solving it. It’s for circumstances almost opposite to an interview.
The proposed solutions don’t even work - for example the tan is only meant to display once per letter.
The actual question does at least ask when it’s JS suitable and when isn’t it - for example it’s irritating to have to wait for a page to init just to be able to access a drop-down menu (hint: use active in CSS instead of a JS toggle).