---
title: "conflicting-provider-properties"
description: "Reports a container or anchor property that a ref method and a utility both set."
image: "https://stillwind.dev/og.png"
---

> Documentation Index
> Fetch the complete documentation index at: https://stillwind.dev/llms.txt
> Use this file to discover all available pages before exploring further.

# conflicting-provider-properties

This rule reports a container or anchor property that a ref method, such as
`asContainer()`, and another utility both set on the same element. For example,
`asContainer("size")` sets `container-type: size`, and `@container` sets it to
`inline-size`. Only one value takes effect, and the code does not show which.

## Reported

```tsx
const card = style.ref("card");
style(card, card.asContainer("size"), "@container");
```

> conflicting-provider-properties: provider use overlaps `container-type` from another source; their order is not guaranteed
> 
> Example:2:40
> 
> Example:2:13: overlapping property source

## Fixed

```tsx
const card = style.ref("card");
style(card, card.asContainer("size"));
```

## How to fix

- Set the property in one place. With a ref, pass the container type to
  `asContainer()`, and remove the utility, as in the example.
- If you want the type from the utility, call `asContainer()` without a type.

## Rule settings

| Preset | Severity |
| --- | --- |
| `recommended` | warn |
| `strict` | deny |
| `stylistic` | off |

[Configure lint](/docs/configuration#lint) to change the severity or options.

Source: https://stillwind.dev/docs/lints/conflicting-provider-properties/index.mdx
