@difizen/mana-syringe
Version:
15 lines (13 loc) • 310 B
text/typescript
import type { Syringe } from './core';
export const OptionSymbol = Symbol.for('SyringeSideOption');
export const registerSideOption = <
T extends Record<any, any> = {
//
},
R = any,
>(
option: Syringe.InjectOption<R>,
target: T,
) => {
Reflect.defineMetadata(OptionSymbol, option, target);
};