> ## Documentation Index
> Fetch the complete documentation index at: https://docs.bijection.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Class: VLiteral<Type, IsOptional>

> Not exported: an exported type refers to it.

[browser](/api/modules/browser).VLiteral

Not exported: an exported type refers to it.

## Type parameters

| Name | Type |
| :- | :- |
| `Type` | `Type` |
| `IsOptional` | extends [`OptionalProperty`](/api/modules/browser#optionalproperty) = `"required"` |

## Hierarchy

* `BaseValidator`\<`Type`, `IsOptional`>

  ↳ **`VLiteral`**

## Constructors

### constructor

• **new VLiteral**\<`Type`, `IsOptional`>(`«destructured»`)

#### Type parameters

| Name | Type |
| :- | :- |
| `Type` | `Type` |
| `IsOptional` | extends [`OptionalProperty`](/api/modules/browser#optionalproperty) = `"required"` |

#### Parameters

| Name | Type |
| :- | :- |
| `«destructured»` | `Object` |
| › `isOptional` | `IsOptional` |
| › `value` | `Type` |

#### Overrides

BaseValidator\&lt;Type, IsOptional\&gt;.constructor

## Properties

### type

• `Readonly` **type**: `Type`

#### Inherited from

BaseValidator.type

***

### fieldPaths

• `Readonly` **fieldPaths**: `never`

#### Inherited from

BaseValidator.fieldPaths

***

### isOptional

• `Readonly` **isOptional**: `IsOptional`

#### Inherited from

BaseValidator.isOptional

***

### isConvexValidator

• `Readonly` **isConvexValidator**: `true`

#### Inherited from

BaseValidator.isConvexValidator

***

### value

• `Readonly` **value**: `Type`

***

### kind

• `Readonly` **kind**: `"literal"`

## Accessors

### json

• `get` **json**(): [`ValidatorJSON`](/api/modules/browser#validatorjson)

#### Returns

[`ValidatorJSON`](/api/modules/browser#validatorjson)

#### Overrides

BaseValidator.json

## Methods

### optional

▸ **optional**(): [`VLiteral`](/api/classes/browser.VLiteral)\<`undefined` | `Type`, `"optional"`>

#### Returns

[`VLiteral`](/api/classes/browser.VLiteral)\<`undefined` | `Type`, `"optional"`>

#### Overrides

BaseValidator.optional

***

### asOptional

▸ **asOptional**(): [`VLiteral`](/api/classes/browser.VLiteral)\<`undefined` | `Type`, `"optional"`>

#### Returns

[`VLiteral`](/api/classes/browser.VLiteral)\<`undefined` | `Type`, `"optional"`>

#### Overrides

BaseValidator.asOptional


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.