Built-in Fields
Name | Is Higher Order | Has attachments | Description | Constructor params | Format params | Example valid values |
---|---|---|---|---|---|---|
Boolean | true or flase | none | none | "true", "false", true, false, 0, 1 | ||
CachedValue | ✅ | Remember a value and only recalculate it when some event occurs | see docs | same as the extended field | same as the extended field | |
Color | Stores a color as string | none | none | "#ff000", "red" | ||
ControlAccess | ✅ | Controls who can display and/or edit the given field | see docs | same as the extended field | same as the extended field | |
Date | Stores a date, as in a day in calendar, without time. | none | none | "2020-12-31" | ||
Datetime | Stores a timestamp as ms since epoch. Timezone-independent. | none | null or "human_readable" | 1610214993421 | ||
DerivedValue | ✅ | Calculates a value based on other fields within the same item and stores it. | see docs | same as the extended field | same as the extended field | |
DisallowUpdate | ✅ | Allows to set the value once and then disallow any changes to it. | one argument - the extended field - a Field instance | same as the extended field | same as the extended field | |
An email address | none | none | "user@example.com" | |||
Enum | Allows only values from a predefined list | an array of allowed values or a function that takes an app instance and returns an array of allowed values | none | as defined in constructor params | ||
File | Any kind of file | none | none | a photo, a movie, a pdf | ||
Float | Any real number | none | none | 1, 1.5, -10, 3.1415926 | ||
Html | Takes text containing HTML and sanitizes it to prevent js injection | none | "original" or "safe" | "<h1>Hello, world</h1>" | ||
Image | An image. Can be scaled to different sizes automatically | none | one of the image formats defined in config | a JPG file | ||
Int | An integer. Takes only whole numbers | {min: number, max: number} | none | 1, 2, -10, 10000 | ||
JsonObject | Takes in arbitrary objects. Could be unsafe, requires investigation. | none | none | {a: "A"} | ||
Password | A hashed password. Used in the users collection | none | none | "alamakota123" | ||
Required | ✅ | Wrapper that makes the wrapped field required. | Warning: this is a function, not a class. Argument: child_field: Field | same as extended field | same as extended field, except for lack of value or null, which will be rejected | |
ReverseSingleReference | ✅ | |||||
File Metadata
File Metadata
- Mime Type
- text/plain
- Expires
- Mon, Dec 23, 10:10 (1 d, 16 h)
- Storage Engine
- blob
- Storage Format
- Raw Data
- Storage Handle
- 556891
- Default Alt Text
- field-types.remarkup (3 KB)