procedure-fns
v1.0.1
Published
easily create procedures within a pit-of-success
Downloads
65
Readme
procedure-fns
easily create procedures within a pit-of-success
install
npm install
use
for example
const procedure: Procedure<{ exid: string }, { dbConnection: DatabaseConnection }, { flag: Flag } | null> = (input, context) => {...}
const input: ProcedureInput<typeof procedure> = { exid: '__exid__' };
const procedureWithExpect = withExpectOutkey(procedure);
const { flag } = await procedureWithExpect({ exid: 'usa' }, context).expect('flag', 'isPresent');