Skip to content

Commit 2d44d56

Browse files
committed
Update control decorator docstring for clarity
Improved the docstring for the control decorator by clarifying references to @DataClass and its keyword arguments, and enhancing formatting for better readability.
1 parent 9589f0a commit 2d44d56

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

sdk/python/packages/flet/src/flet/controls/base_control.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -53,14 +53,14 @@ def control(
5353
) -> Union[type[T], Callable[[type[T]], type[T]]]:
5454
"""
5555
Decorator to optionally set widget name and 'isolated' while behaving
56-
like @dataclass.
56+
like [`@dataclass`][dataclasses.dataclass].
5757
5858
Parameters:
5959
dart_widget_name: The name of widget on Dart side.
6060
isolated: If `True`, marks the control as isolated. An isolated control
6161
is excluded from page updates when its parent control is updated.
6262
post_init_args: Number of InitVar arguments to pass to __post_init__.
63-
dataclass_kwargs: Additional keyword arguments passed to @dataclass.
63+
**dataclass_kwargs: Additional keyword arguments passed to `@dataclass`.
6464
6565
Usage:
6666
- Supports `@control` (without parentheses)

0 commit comments

Comments
 (0)