> For the complete documentation index, see [llms.txt](https://jsf.gitbook.io/jsf/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://jsf.gitbook.io/jsf/schema/property-options.md).

# Prop options

All props share some common properties that can help you change the default behavior.

## type

Defines prop type, valid values are **null, object, array, string, number, integer, date, boolean, id, binary**.

## $comment

Intended for notes to schema maintainers, as opposed to "description" which is suitable for display to end users.

## default

&#x20;The `default` keyword specifies a default value for an property.  Additional you can overwrite  default with `advancedDefault` keyword. With `advancedDefault` you can set default from URL query component value or from custom JavaScript code.

Bottom example first tries to set default from `http://localhost?email=`` `**`URL encoded value`** if not found it will fallback to `default` keyword.

```javascript
"email": {
  "type": "string",
  "format": "email",
  "default": "info@example.com",
  "advancedDefault": {
    "query": "email"
  }
}
```

**`default` interface**

Value must be same type as property type.

### advancedDefault

**`advancedDefault` interface**

| Parameters | Type     | Description                                                                                    |
| ---------- | -------- | ---------------------------------------------------------------------------------------------- |
| query      | `string` |                                                                                                |
| $eval      | `string` | <p>Custom JavaScript code. Code must return value.</p><p>Example: <code>return 123;</code></p> |

## const

Force value of prop. Can't be changed.

## required

If `required: true` prop value is required.

## virtual

Props that have `virtual: true` will be ignored when calling `getValue({ virtual: false})`.

## nullable

{% hint style="danger" %}
Experimental
{% endhint %}

## readonly

If `readonly: true` input field is disabled.

## writeonly

{% hint style="info" %}
Depends on your API implementation.
{% endhint %}

## searchable

{% hint style="warning" %}
Depends on APP and API implementation. Not directly used in JSF core.
{% endhint %}

```
searchable?: {

    title?: string;

    /**
     * If enabled it will be displayed to user under More button, when using advanced search.
     */
    byUser?: {

      /**
       * Only show search field if specific mode is present.
       */
      $mode?: string;
      enabled?: true;
    }
  }
```
