import type * as CfTypes from './cf-types.ts'; export declare namespace HelperTypes { type AnyDON = CfTypes.DurableObjectNamespace; type DOKeys = { [K in keyof T]-?: T[K] extends AnyDON ? K : never; }[keyof T]; /** * Helper type to extract DurableObject keys from Env to give consumer type safety. * * @example * ```ts * type PlatformEnv = { * DB: D1Database * ADMIN_TOKEN: string * SYNC_BACKEND_DO: DurableObjectNamespace * } * export default makeWorker({ * syncBackendBinding: 'SYNC_BACKEND_DO', * // ^ (property) syncBackendBinding: "SYNC_BACKEND_DO" * }); */ export type ExtractDurableObjectKeys = DOKeys extends never ? string : DOKeys & string; export {}; } //# sourceMappingURL=helper.d.ts.map