# APPLICATION\_TYPES

## Overview

Constants are defined to represent different application types, each assigned a numeric value. These constants enable applications to identify and handle specific client environments dynamically. The constants include:

* **HEADLESS\_CLIENT**: Represents a headless client.
* **MOBILE\_CLIENT**: Represents a mobile client.
* **NG\_CLIENT**: Represents an NG client.

## Key Points

* **Type**: All constants are of type `Number`.
* **Usage**: These constants can be used in conditional logic to execute code tailored for the respective application type.

These constants provide a structured approach to managing diverse application environments, ensuring that applications can adapt their behavior based on the client type dynamically and efficiently.

## Constants Summarized

| Type                                                                         | Name                                 | Summary                                         |
| ---------------------------------------------------------------------------- | ------------------------------------ | ----------------------------------------------- |
| [Number](https://docs.servoy.com/reference/servoycore/dev-api/js-lib/number) | [HEADLESS\_CLIENT](#headless_client) | Constant for application type headless\_client. |
| [Number](https://docs.servoy.com/reference/servoycore/dev-api/js-lib/number) | [MOBILE\_CLIENT](#mobile_client)     | Constant for application type mobile client.    |
| [Number](https://docs.servoy.com/reference/servoycore/dev-api/js-lib/number) | [NG\_CLIENT](#ng_client)             | Constant for application type ng client.        |

## Constants Detailed

### HEADLESS\_CLIENT

Constant for application type headless\_client.

**Type**\
[Number](https://docs.servoy.com/reference/servoycore/dev-api/js-lib/number)

**Sample**

```js
if (application.getApplicationType() == APPLICATION_TYPES.HEADLESS_CLIENT)
{
	//we are in headless_client
}
```

### MOBILE\_CLIENT

Constant for application type mobile client.

**Type**\
[Number](https://docs.servoy.com/reference/servoycore/dev-api/js-lib/number)

**Sample**

```js
if (application.getApplicationType() == APPLICATION_TYPES.MOBILE_CLIENT)
{
	//we are in mobile client
}
```

### NG\_CLIENT

Constant for application type ng client.

**Type**\
[Number](https://docs.servoy.com/reference/servoycore/dev-api/js-lib/number)

**Sample**

```js
if (application.getApplicationType() == APPLICATION_TYPES.NG_CLIENT)
{
	//we are in mobile client
}
```

***
