I understand the "starting point" part but I find the emphasis on "classless" interesting: you basically have to introduce a non-element selector as soon as you want make even the smallest layout change.
For anything beyond a single page document, I find something like matcha.css (https://matcha.mizu.sh, you can even pick your custom build on the same page) a practical starting point if you want to stay close to the elements.
I tend to start a project by making a classless stylesheet of sorts to set a baseline for the theme and branding.
Its almost never all you need for an actual project, but it is a nice starting point to get the basics in place.
I find that I look at the endless list of classless stylesheets shared online as a starting point, most have at least one or two interesting tricks worth borrowing. I don't find using the off the shelf ones particularly useful though, it ends up with a very generic look to it like the old default bootstrap site or newer default tailwind site.
/* define layer order. Not necessary here */
@layer pico, nils;
/* import framework into layer */
@import url("pico.css") layer(pico);
/* define own styles in own layer, they have precedence. CSS vars are still global. */
@layer nils {
p:first-of-type {
color: green;
}
}
Love the idea. It's really painful to cycle through every theme. Would be great to have a way to scroll through them directly, though... that would result in a bigger bundle, and I respect the hustle
I was very curious for the reason and I found it. Cssbed is not hosting css files but loading upstream css and https://vanillacss.com/vanilla.css has been hacked/hijacked, so no css is being loaded but HTML full of crap.
I thought if request origin or content-type was stylesheet no href GET should be triggered (maybe src) but looks like full HTML site is being rendered behind the scenes of a simple css request.
OP frankly can't be a serious dev with results like these. It's most likely slop. This looks like a CV project to impress some HR Karens with HN/github clout, to land a job as an AI meat proxy...
Just checked - now the homepage of the BBC on load has a transfer of 1.5MB with 5.7MB of resources, and once you've scrolled down the page for the lazy loaded images those figures are 2.9MB and 7.2MB respectively.
Well, μ- is a million times bigger than p-. But last time I looked <https://news.ycombinator.com/item?id=45163827>, Pico CSS was 83 kB—nowhere near as small as that name would suggest, either.
I used chota.css (https://jenil.github.io/chota/) in the past to build a couple internal sites for my then-employer. Only ~3kb compressed! And the name stays relevant-ish because it means "small" in Hindi...
Edited to add: it's not classless though. Marx would disapprove.
I had a server-side app made for personal stuff, and pico.css drop-in is a pretty good baseline for an usable UI/page. Also visited some web hosts and their sites look perfectly serviceable with Bootstrap. I think it's a good way to railroad some of the more egregious things LLMs might do with regards to CSS.
I have not written any CSS from scratch since years. Does normalize.css/reset.css are still viable and used? I use Tailwind because of components design, so I wonder what actually current trends are in context of small/alternative CSS solutions.
Resets are still viable. They've become shorter over the years as css has advanced. Obviously if you write Tailwind you don't need a reset.
For small/alternative stuff, since nesting/has()/ field sizing and such is native now there's not much to do there, so what's mostly relevant is some classless sheets like what this article is about.
Interesting. Having made websites I think "of course that makes sense!". As a practical matter, getting wanted page appearance can require adding a few classes. I've been guilty of class proliferation caused by perfectionistic tweaking of things to the last nanogram. Anymore I strive not to go there.
Eye opener. I think I looked through almost all of them and none got basic typography right such as less margin bottom beneath a heading (to the paragraph following it) than above.
Not only that, but very few of them differentiate between a visited link and an unvisited one. I noticed this immediately when clicking through the list of themes and getting no visual indication of which ones I'd already looked at.
I love classless CSS for rapid hand prototyping. LLMs are making this increasingly less necessary, but it's still great for creating tiny, performant CSS pages and some of the smaller ones can even be inlined in fewer bytes than it takes to make a 2nd round trip to the server to check if the asset has been updated. This is one of my secret weapons for creating web apps that load and render so fast you can feel the difference!
https://dohliam.github.io/dropin-minimal-css/
reply