# Interface: PixiVNJsonIfElse<Then> (/jsdoc/pixi-vn-json/index/interfaces/PixiVNJsonIfElse)



Defined in: [src/schema/PixiVNJsonIfElse.ts:8](https://github.com/DRincs-Productions/pixi-vn-json/blob/336c45bc1f677c3b088aac058f0a457afc7cf32e/src/schema/PixiVNJsonIfElse.ts#L8)

If-Else condition for PixiVNJson

Type Parameters [#type-parameters]

Then [#then]

`Then`

Properties [#properties]

condition [#condition]

\> **condition**: [`PixiVNJsonConditions`](/jsdoc/pixi-vn-json/index/type-aliases/PixiVNJsonConditions)

Defined in: [src/schema/PixiVNJsonIfElse.ts:20](https://github.com/DRincs-Productions/pixi-vn-json/blob/336c45bc1f677c3b088aac058f0a457afc7cf32e/src/schema/PixiVNJsonIfElse.ts#L20)

The list of conditions to be checked.

if is a StorageElementType or a [PixiVNJsonValueGet](/jsdoc/pixi-vn-json/index/type-aliases/PixiVNJsonValueGet):

* if is a array or object, the condition is true if not empty
* if is a string, the condition is true if not empty
* if is a number, the condition is true if not zero
* if is a boolean, the condition is true if true
* if is null or undefined, the condition is false

***

else? [#else]

\> `optional` &#x2A;*else?**: `PixiVNJsonIfElse`\<`Then`> | `Then`

Defined in: [src/schema/PixiVNJsonIfElse.ts:28](https://github.com/DRincs-Productions/pixi-vn-json/blob/336c45bc1f677c3b088aac058f0a457afc7cf32e/src/schema/PixiVNJsonIfElse.ts#L28)

The value to be returned if the condition is false.

***

then [#then-1]

\> **then**: `PixiVNJsonIfElse`\<`Then`> | `Then`

Defined in: [src/schema/PixiVNJsonIfElse.ts:24](https://github.com/DRincs-Productions/pixi-vn-json/blob/336c45bc1f677c3b088aac058f0a457afc7cf32e/src/schema/PixiVNJsonIfElse.ts#L24)

The value to be returned if the condition is true.

***

type [#type]

\> **type**: `"ifelse"`

Defined in: [src/schema/PixiVNJsonIfElse.ts:9](https://github.com/DRincs-Productions/pixi-vn-json/blob/336c45bc1f677c3b088aac058f0a457afc7cf32e/src/schema/PixiVNJsonIfElse.ts#L9)
