Skip to content

extendMaker

extendMaker<TBaseComps, TBaseOpt, TNewComps, TNewOpt>(baseMaker, defaultOpt, componentsApply): MakerFN<TNewOpt & TBaseOpt, TNewComps & TBaseComps>

Extend a maker with new components.

Type parameters

Type parameterDescription
TBaseCompsThe base components from the base maker
TBaseOptThe base options from the base maker
TNewCompsThe new components added to the base
TNewOptThe new options added to the base

Parameters

ParameterTypeDescription
baseMakerMakerFN<TBaseOpt, TBaseComps>The base maker to extend. Example: makeObject
defaultOptOptionFN<TNewOpt> | OptionFN<TNewOpt & TBaseOpt>An options object created with makeOptions
componentsApplyApplierFN<TNewComps, TNewOpt & TBaseOpt>-

Returns

MakerFN<TNewOpt & TBaseOpt, TNewComps & TBaseComps>

A new maker with the new components and options

Source

global.d.ts:12