# default

## Effect

Set the return value of `validate` and `validateSilent`, when the detected value is `undefined | null`.

## Arguments

* `value` ***(\*)*** - The default return value of `validate` and `validateSilent`. It is recommended but not necessarily to be a boolean. When `value` is a function, then set the return value of `value` to be the default return value. *The function has a parameter: the original detected value - `undefined`or `null`.*
* `[ctx]` ***(\*) -*** The execution context if `value` is a function.

## Example

```javascript
const schema = racoon.boolean().default(false);
schema.validate(undefined); // pass, return: false
schema.validate(null); // pass, return: false
```
