import createApp , { BaseApp , AppConfig } from "../shared/createApp" ; import deliverCtrl , { DeliverCtrl } from "./deliver" ; export interface DeliverApp extends BaseApp { deliver : DeliverCtrl ; } export default async ( config ) : Promise < DeliverApp > => { const app = < DeliverApp > await createApp ( config ) ; app . deliver = await deliverCtrl ( app ) ; return app ; } ;