Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions custom_types/csstree-validator.d.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
declare module 'csstree-validator';
30 changes: 30 additions & 0 deletions docs/rules/no-invalid-css.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
# Disallows invalid CSS in templates (no-invalid-css)

Templates should all contain valid CSS, if any, as it is expected
to be parsed as part of rendering.

## Rule Details

This rule disallows invalid CSS in templates.

The following patterns are considered warnings:

```ts
css`foo bar`;
css`.footer { 24px; color: blue; }`;
```

The following patterns are not warnings:

```ts
css`
.header {
margin: 24px;
color: blue;
}
`;
```

## When Not To Use It

If you don't care about invalid CSS, then you will not need this rule.
199 changes: 196 additions & 3 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading