-
Notifications
You must be signed in to change notification settings - Fork 25
regula.Group
vivin edited this page Jul 19, 2012
·
6 revisions
regula.Group is similar to an enum, and provides a convenient way to refer to constraints without using “magic” strings. Javascript does not have true enums, so technically Group is simply a map. Although the individual types in the map resolve to integer values, do not rely on the actual integer value. It is safer to use the enum.
- Default
Note: Whenever you bind an element to a group either through HTML or programmatically, Group is updated to contain your new group. Therefore, if you added a constraint to a group called MyGroup, you can now access the new group by doing regula.Group.MyGroup.