View Issue Details

IDProjectCategoryView StatusLast Update
4953Composrcorepublic2024-08-04 22:25
ReporterChris Graham Assigned ToGuest  
PrioritynormalSeverityfeature 
Status newResolutionopen 
Summary4953: Implement CSS nesting
DescriptionW3C are working on a spec to allow nesting:
https://drafts.csswg.org/css-nesting/

It would make our CSS more readable. It's a problem how complex and convoluted CSS has become, and this helps solve that.

At the time of writing no browsers support it.

Consider switching our CSS to use it once possible. Maybe even a tool can automatically apply the changes.

Even if not all main browsers support it, we could consider compiling to regular CSS as part of our CSS processing. Probably someone will even make a tool for that.
TagsRoadmap: Over the horizon, Type: Standards compliance
Attach Tags
Time estimation (hours)16
Sponsorship open

Sponsor

Date Added Member Amount Sponsored

Activities

Chris Graham

2024-08-04 20:40

administrator   ~9078

This is now widely supported.

https://caniuse.com/?search=css%20nesting

PDStig

2024-08-04 22:25

administrator   ~9089

Last edited: 2024-08-04 22:25

I don't know if I like it personally. For me, the non-nested version is more readable and understandable because then I don't have to keep scrolling up to see which classes / selectors apply to what. I'd definitely like to also implement to/from compiler tools along with this.

Add Note

View Status
Note
Upload Files
Maximum size: 32,768 KiB

Attach files by dragging & dropping, selecting or pasting them.
You are not logged in You are not logged in. This means you will not get any e-mail notifications. And if you reply, we will not know for sure you are the original poster of the issue.

Issue History

Date Modified Username Field Change
2022-09-27 17:30 Chris Graham New Issue
2022-09-27 17:30 Chris Graham Tag Attached: Type: Standards compliance
2024-08-04 20:40 Chris Graham Summary Implement CSS nesting (holding issue) => Implement CSS nesting
2024-08-04 20:40 Chris Graham Note Added: 0009078
2024-08-04 22:25 PDStig Note Added: 0009089
2024-08-04 22:25 PDStig Tag Attached: Roadmap: Over the horizon
2024-08-04 22:25 PDStig Note Edited: 0009089