Repository navigation
Fix syntax error in styled-components v6 handling - #5635
Conversation
🦋 Changeset detectedLatest commit: 867cf07 The changes in this PR will be included in the next version bump. This PR includes changesets to release 1 package
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
… braces Co-authored-by: quantizor <[email protected]>
Co-authored-by: quantizor <[email protected]>
|
@copilot explore other classes / variations of this problem such as other types of rule-like incomplete syntax causing broken css. the library's default behavior should be to contain invalid syntax to just the affected line |
Co-authored-by: quantizor <[email protected]>
|
@copilot resume |
Co-authored-by: quantizor <[email protected]>
Co-authored-by: quantizor <[email protected]>
Resumed and completed the work. In commit
All 404 web tests and 37 native tests pass. CodeQL security check found no issues. |
|
@copilot try to further optimize sanitizeCSS as it is the hottest path in the system. analyze branching complexity, short circuiting optimizations, polymorphism etc. Use microbenchmarks to validate approaches. |
Co-authored-by: quantizor <[email protected]>
Optimized in commit Valid CSS (most common case): 70x faster
CSS with comments: 3.5x faster
Optimizations applied:
All 404 tests pass. |
|
@copilot Need a changeset for the comment fix |
Co-authored-by: quantizor <[email protected]>
Added separate changeset for the line comment fix in commit
|
|
@copilot Run the formatter |
Co-authored-by: quantizor <[email protected]>
Done in commit |
}as closing the rule blockutils/stylis.ts:stripLineComments(): Strips JS-style//comments anywhere in CSS (fixes Line comments are not supported in multiline style declarations #5613)hasUnbalancedBraces(): Fast check for CSS with brace issuessanitizeCSS(): Removes only problematic declarations while preserving valid ones//or}foundOriginal prompt
✨ Let Copilot coding agent set things up for you — coding agent works faster and does higher quality work when set up for your repo.