UNPKG

domain-objects

Version:

A simple, convenient way to represent domain objects, leverage domain knowledge, and add runtime validation in your code base.

11 lines (10 loc) 563 B
import type { DomainEntity } from '../instantiation/DomainEntity'; /** * Extracts an object that contains only the updatable properties of the domain object, for DomainEntity * * Uses the definition of a DomainEntity in order to extract the properties that are updatable for the domain object generically * * note * - this should not be called on DomainLiterals or DomainEvents, since by definition they can not have updatable properties */ export declare const getUpdatableProperties: <T extends Record<string, any>>(dobj: DomainEntity<T>) => Partial<T>;