Personally I prefer to write the CSS (well Sass really). I've mainly used Bootstrap in the past. I've moved on though, I learned flexbox and css grid and some atomic design principals as well as ABEM ( https://css-tricks.com/abem-useful-adaptation-bem/ ) and I'm happy.
Once I discovered utility classes, I found it so much better than BEM or any derivatives of such. I don't want my styles to know what my components are, I want my components to use predefined styles.
Show HN: Blunt – A CSS Layout Framework for Minimalists
41–50 of 76 posts
Re: Show HN: Blunt – A CSS Layout Framework for Minimalists
#42Personally I prefer to write the CSS (well Sass really). I've mainly used Bootstrap in the past. I've moved on though, I learned flexbox and css grid and some atomic design principals as well as ABEM ( https://css-tricks.com/abem-useful-adaptation-bem/ ) and I'm happy.
Re: Show HN: Blunt – A CSS Layout Framework for Minimalists
#43Simple responsive card:
Re: Show HN: Blunt – A CSS Layout Framework for Minimalists
#44Personally I prefer to write the CSS (well Sass really). I've mainly used Bootstrap in the past. I've moved on though, I learned flexbox and css grid and some atomic design principals as well as ABEM ( https://css-tricks.com/abem-useful-adaptation-bem/ ) and I'm happy.
I don't mind hand-writing CSS for a small project, but I feel like once you've got a decent team, it ends up being duplicative and wasting a lot of time. How many times do you really need to style button/link and write out your 8px margins (or is it 6?) Sass solves this too, but simply applying classes is even easier and faster for me at least. I thought BEM was horrible when I first saw it, but once I used it, the p…
Re: Show HN: Blunt – A CSS Layout Framework for Minimalists
#45Earlier quoted context omitted.
Tailwind has a class for almost everything, which makes it quite heavy: 1600kb minified. In my experience you end up with ≤ 15kb of minified CSS after running PurgeCSS anyway, so this is not an issue. Personally I prefer Tailwind because you practically don't have to write any CSS. With something like Blunt expect finding many edge cases where you will have to write custom CSS. I do write custom classes that wrap Tai…
Going slightly off topic but I wonder if anyone can point me to a tailwind "starter kit" - ie. a project with everything in place to get going with tailwind, postcss etc. Thanks!
Re: Show HN: Blunt – A CSS Layout Framework for Minimalists
#46Personally I prefer to write the CSS (well Sass really). I've mainly used Bootstrap in the past. I've moved on though, I learned flexbox and css grid and some atomic design principals as well as ABEM ( https://css-tricks.com/abem-useful-adaptation-bem/ ) and I'm happy.
I don't mind hand-writing CSS for a small project, but I feel like once you've got a decent team, it ends up being duplicative and wasting a lot of time. How many times do you really need to style button/link and write out your 8px margins (or is it 6?) Sass solves this too, but simply applying classes is even easier and faster for me at least. I thought BEM was horrible when I first saw it, but once I used it, the p…
Either 0 or 1 times. Use semantic classes `` and use custom properties or the cascade from there: :root {
--button-margin-block: 1ex;
--button-margin-inline: 1em;
}
dialog {
/*
* Modals buttons need more block space and
* less inline space.
*/
--button-margin-block: 1em;
--button-margin-inline: 1ex;
}
button,
.button {
margin-block: var(--button-margin-block);
margin-inline: var(--button-margin-inline);
}
Re: Show HN: Blunt – A CSS Layout Framework for Minimalists
#47And if you're truly minimalist,
A- you don't need a framework
B- you don't pollute every html tags with tons of classes.
Re: Show HN: Blunt – A CSS Layout Framework for Minimalists
#48Earlier quoted context omitted.
I don't mind hand-writing CSS for a small project, but I feel like once you've got a decent team, it ends up being duplicative and wasting a lot of time. How many times do you really need to style button/link and write out your 8px margins (or is it 6?) Sass solves this too, but simply applying classes is even easier and faster for me at least. I thought BEM was horrible when I first saw it, but once I used it, the p…
Writing actual CSS is the waste of time. SASS variables, mixins, and the "&" operator are pretty much indespensable.
[1]: https://developer.mozilla.org/en-US/docs/Web/CSS/--*
[2]: https://drafts.csswg.org/css-nesting-1/
[3]: https://postcss.org/
Re: Show HN: Blunt – A CSS Layout Framework for Minimalists
#49Sorry if I sound snarky, but why use this if you can just write: Center It looks like these are just single rule classes. In my opinion, If you are going to write one class for each style rule, you might as well use the style property.
On top of what others are saying, on modern websites, inline CSS is usually forbidden by the Content-Security-Policy, to provide defense in depth against CSS injection. (This SO answer summarizes why CSS injection is something to care about: https://stackoverflow.com/a/718614 )
It's almost trivial to set up a keylogger with css that fires requests on keyboard input. Luckily there's CSP.
Re: Show HN: Blunt – A CSS Layout Framework for Minimalists
#50Sorry if I sound snarky, but why use this if you can just write: Center It looks like these are just single rule classes. In my opinion, If you are going to write one class for each style rule, you might as well use the style property.
On top of what others are saying, on modern websites, inline CSS is usually forbidden by the Content-Security-Policy, to provide defense in depth against CSS injection. (This SO answer summarizes why CSS injection is something to care about: https://stackoverflow.com/a/718614 )