# Issues creating rules in CSS

**URL:** <https://forum.pinegrow.com/t/issues-creating-rules-in-css/2651>\
**Category:** Styling (CSS)\
**Tags:** bug\
**Created:** [January 29, 2019, 4:43pm UTC](https://forum.pinegrow.com/t/issues-creating-rules-in-css/2651 "2019-01-29T16:43:17Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![casay](https://avatars.discourse-cdn.com/v4/letter/c/8797f3/32.png) [@casay](https://forum.pinegrow.com/u/casay)\
**Post date:** [January 29, 2019, 4:43pm UTC](https://forum.pinegrow.com/t/issues-creating-rules-in-css/2651/1 "2019-01-29T16:43:17Z")

</div>

After creating a new rule in CSS my style attribute then shows classes without rules as the rule I just created.

for example I create the rule - .body

It then shows classes without rules: body

I then check my css stylesheet and it has written the code as follows.

.body {  
};  
}

is this some sort of bug or is there something I am doing wrong?

Even after I edit the css stylesheet it still indicates that my class does not have rules.

---

<div class="post-metadata">

**Author:** ![Marf](https://yyz2.discourse-cdn.com/flex036/user_avatar/forum.pinegrow.com/marf/32/1799_2.png) [@Marf](https://forum.pinegrow.com/u/Marf)\
**Post date:** [January 29, 2019, 6:51pm UTC](https://forum.pinegrow.com/t/issues-creating-rules-in-css/2651/2 "2019-01-29T18:51:33Z")

</div>

Don’t know how/why you got this, but this code is invalid and the reason why Pinegrow do not recognize it correctly!

```
.body {
};
}

```

Change it to this, to make it valid (what you might already know):

```
.body {
}

```

The warning **“classes without rules: body”** shall disappear!

* * *

I reproduced the steps you described, and Pinegrow creates this for me which is correct and valid.

```
.body {
}

```

I don’t know why it went wrong with you! Maybe there is something wrong with other rules in your CSS file, and you have a **}** or **{** too much or is missing somewhere.

* * *

> [@casay](#):
>
> Even after I edit the css stylesheet it still indicates that my class does not have rules.

Maybe need to “refresh” or “reload” the CSS file, to show the changes.

* * *
