Skip to content
This repository has been archived by the owner on Oct 23, 2021. It is now read-only.

sp core library.validate.isnotnullorundefined

John Nguyen edited this page Apr 22, 2021 · 2 revisions

Home > @microsoft/sp-core-library > Validate > isNotNullOrUndefined

Validate.isNotNullOrUndefined() method

Throws an exception if the specified value is null or undefined.

Signature:

static isNotNullOrUndefined(value: any, variableName: string): void;

Parameters

Parameter Type Description
value any the value to check
variableName string the program variable name, which will be mentioned in the error message

Returns:

void

Clone this wiki locally