From ce0f54a8911fb495e749771b775bbd92caba5a86 Mon Sep 17 00:00:00 2001 From: wolfy1339 <4595477+wolfy1339@users.noreply.github.com> Date: Mon, 22 Oct 2018 11:50:43 -0400 Subject: [PATCH] [pouchdb-core] Fix Blob interface by including dom (#29755) * [pouchdb-core] Fix Blob interface by including dom error TS2304: Cannot find name 'Blob' * [pouchdb-core] duplicate Blob interface inline (#1) Forward declare Blob instead of using a triple-slash directive. /// looks for 'dom' in Definitely Typed, but the 'dom' lib is built into TypeScript. --- types/pouchdb-core/index.d.ts | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/types/pouchdb-core/index.d.ts b/types/pouchdb-core/index.d.ts index 0dbf5def5b..63f03a6832 100644 --- a/types/pouchdb-core/index.d.ts +++ b/types/pouchdb-core/index.d.ts @@ -9,6 +9,12 @@ /// /// +interface Blob { + readonly size: number; + readonly type: string; + slice(start?: number, end?: number, contentType?: string): Blob; +} + interface Buffer extends Uint8Array { write(string: string, offset?: number, length?: number, encoding?: string): number; toString(encoding?: string, start?: number, end?: number): string;