Is::JSON()

Checks for valid JSON string.

Table of Contents
  1. Description
  2. Example

Description

Is::JSON(mixed $value): bool;

This method checks that the input provided is a valid JSON string.

Example

if (Is::JSON('{"foo":"bar"}')) {
    // …
}

Is::JSON()

Checks for valid JSON string.

Is::file()

Checks if current input is a valid file path.

Is::path()

Checks if current input is a valid path.

Is::void()

Checks for empty string, array and object.