API reference@evolu/commonResult › ok

Call Signature

function ok(): Result<void>;

Defined in: packages/common/src/Result.ts:329

Creates an Ok result.

  • ok() creates a Result<void, never> for operations that succeed without producing a value.
  • ok(value) creates a Result<T, never> containing the specified value.

Call Signature

function ok<T>(value: T): Result<T>;

Defined in: packages/common/src/Result.ts:331

Creates an Ok result with a specified value.