diff --git a/docs/core/entity.md b/docs/core/entity.md index 565fdf82..e22983cf 100644 --- a/docs/core/entity.md +++ b/docs/core/entity.md @@ -270,20 +270,13 @@ from homeassistant.helpers.typing import StateType from .const import DOMAIN, LOGGER -@dataclass -class ExampleSensorEntityDescriptionMixin: - """Mixin for required keys.""" - value_fn: Callable[[ExampleDevice], StateType] - - -@dataclass -class ExampleSensorEntityDescription( - SensorEntityDescription, ExampleSensorEntityDescriptionMixin -): +@dataclass(kw_only=True) +class ExampleSensorEntityDescription(SensorEntityDescription): """Describes Example sensor entity.""" exists_fn: Callable[[ExampleDevice], bool] = lambda _: True + value_fn: Callable[[ExampleDevice], StateType] SENSORS: tuple[ExampleSensorEntityDescription, ...] = (