Back to Emotion

eslint-plugin-react

docs/eslint-plugin-react.mdx

10.0.6584 B
Original Source

The react/no-unknown-property rule from eslint-plugin-react will produce an error if the css prop is passed to a DOM element. This violation of the rule can be safely ignored because @emotion/react intercepts the css prop before it is applied to the DOM element.

The rule can be configured to ignore the css prop like so:

json
{
  "rules": {
    "react/no-unknown-property": ["error", { "ignore": ["css"] }]
  }
}