-
-
Notifications
You must be signed in to change notification settings - Fork 24
Closed
Labels
acceptedThere is consensus among the team that this change meets the criteria for inclusionThere is consensus among the team that this change meets the criteria for inclusionfeature
Description
Rule details
Disallow invalid named grid areas.
What type of rule is this?
Warns about a potential problem
Example code
a { grid-template-areas: "a a a"
"b b b b"; }
Prior Art
named-grid-areas-no-invalid from stylelint
Participation
- I am willing to submit a pull request to implement this rule.To pick up a draggable item, press the space bar. While dragging, use the arrow keys to move the item. Press space again to drop the item in its new position, or press escape to cancel.
Additional comments
For a named grid area to be valid, all strings must define:
- the same number of cell tokens
- at least one cell token
And all named grid areas that spans multiple grid cells must form a single filled-in rectangle.
Metadata
Metadata
Assignees
Labels
acceptedThere is consensus among the team that this change meets the criteria for inclusionThere is consensus among the team that this change meets the criteria for inclusionfeature
Type
Projects
Status
Complete
Milestone
Relationships
Development
Select code repository
Activity
nzakas commentedon Jun 2, 2025
Just to double-check, this isn't already caught by
no-invalid-properties
, correct?xbinaryx commentedon Jun 3, 2025
That's correct, it's not.
nzakas commentedon Jun 3, 2025
Tentatively marked as accepted. Can you take a look and see if there's any other grid-specific validation that this rule can do? I'm generally not a fan of rules that are laser-focused on just one thing, so if there's anything else that can be added, I'd be interested in hearing about it.
xbinaryx commentedon Jun 9, 2025
I've reviewed the rule again and explored existing Stylelint rules, but I haven't been able to identify any other grid-specific validations that could be incorporated into this rule.