0

According to MDN:

The <bg-size> value may only be included immediately after <position>, separated with the '/' character, like this: "center/80%".

Is there any way to check this rule?

Vail
  • 3
  • 2

1 Answers1

0

You wish to check the validity of your CSS code against the specifications, which is best done with a validator like CSSTree.

You can use the stylelint-csstree-validator stylelint plugin to run this validator within stylelint.

(You can test the validator online and it will flag a misformed background value, including a misplaced <bg-size>.)

jeddy3
  • 3,451
  • 1
  • 12
  • 21