r/webdev • • 12d ago

Showoff Saturday modest-ui: classless CSS that styles plain HTML

I’ve been building websites for over a decade, and have always tried to do things as vanilla as possible (where applicable).

More recently whilst building components and looking at the libraries out there, I realised that browser technology and CSS has grown to a point where it can do the majority of things we need, without JS (like dialog, detail, and popover tags)

So I started working on modest-ui as a CSS base for all my personal and side projects, and as it’s gotten more stable I’ve recently bumped it to v2.

It’s themeable with CSS vars, can be used as an unobtrusive base layer to built on top of, and can either be used classless (with mdst-ui set on the body) or you can pick and choose classes as needed.

Anyway, it’s open source (MIT), no JS (except for some examples on the site), and currently sits at about 10 kb (gzipped).

https://github.com/thisismodest/modest-ui
https://modest-ui.com

Edit: I forgot to mention it’s ~10kb when gzipped

103 Upvotes

31 comments sorted by

View all comments

Show parent comment

2

u/deveronipizza 10d ago

I see, like a data attribute.

0

u/waterkip 10d ago

Like an attribute yes.

1

u/St34thdr1v3R 8d ago

They specifically meant data-* Attributes which is the recommended way to avoid naming clashes: https://www.w3schools.com/tags/att_data-.asp

1

u/waterkip 8d ago edited 8d ago

Yes I know what they meant and no I don't use them. Which is why I said what I said. If you want to implement them as data-* or x-* feel free to do so. 

You could also opt for namespace-*, its is unlikely to become a standard attribute: waterkip-lead, but its ugly and when the w3c introduces something I'm using, I can go nag about the w3c. Win-win.