This documentation describes unreleased changes on the main branch.

Format

Enum backed by string.

use Saij\WpAppFramework\Rest\Format;

String formats supported by the WordPress REST schema (rest_validate_value_from_schema() and rest_sanitize_value_from_schema()).

WordPress validates hex-color, date-time, email, ip and uuid; uri, text-field and textarea-field only sanitize the value.

Cases

CaseValueDescription
HexColor'hex-color'
DateTime'date-time'
Email'email'
Uri'uri'
Ip'ip'
Uuid'uuid'
TextField'text-field'
TextareaField'textarea-field'