Skip to content

Commit a39224f

Browse files
committed
expresion number coersion notes
1 parent a58d736 commit a39224f

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

  • for-developers/module-development/api-changes

for-developers/module-development/api-changes/v2.0.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -127,7 +127,7 @@ Currently this applies to each field you define when:
127127

128128
When executing expressions in option values, Companion will ensure the computed value is valid according to the field definition. This means:
129129

130-
- For a `number` field, the value will be clamped to the `min` and `max` you provide
130+
- For a `number` field, the value will be coerced to a number. If `clampValues: true` is set, it will be clamped to the `min` and `max` you provide, otherwise it will be fail validation. If `asInteger: true` is set, it will be rounded to the nearest integer value, before checking min/max.
131131
- For a `dropdown` field, the value must be a valid option (unless `useCustom: true`, in which case any string is accepted)
132132
- Similar behaviour applies to other field types
133133

0 commit comments

Comments
 (0)