Skip to content

Commit c9c5c44

Browse files
committed
Support eventHandler tags for elements
1 parent 6d86443 commit c9c5c44

File tree

1 file changed

+7
-1
lines changed

1 file changed

+7
-1
lines changed

Sources/DynamicUI/DynamicUIComponent.swift

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,9 +26,15 @@ public struct DynamicUIComponent: Codable, Hashable {
2626
/// Component identifier
2727
///
2828
/// The component identifier can be used to have an identifier if you need react on callback calls
29-
/// This is optional but recommended if you use a callback function
29+
/// This is optional but recommended if you use a event handler function
3030
public let identifier: String?
3131

32+
/// Event handler
33+
///
34+
/// The event handler is called when the component is interacted with.
35+
/// This can be a button press, a slider change, etc.
36+
public let eventHandler: String?
37+
3238
/// Default value of component
3339
public let defaultValue: AnyCodable?
3440

0 commit comments

Comments
 (0)