From d957ad762df22aebac899f0a96ecb79cc6f1da9d Mon Sep 17 00:00:00 2001 From: Roman Hotsiy Date: Thu, 31 May 2018 12:53:38 +0300 Subject: [PATCH] fix: fix typings on npm --- .npmignore | 2 +- custom.d.ts | 4 ---- src/types/index.d.ts | 5 +++++ 3 files changed, 6 insertions(+), 5 deletions(-) diff --git a/.npmignore b/.npmignore index 7ffbfdf0..56abd88f 100644 --- a/.npmignore +++ b/.npmignore @@ -1,6 +1,6 @@ * !bundles/* -!typings/* +!typings/**/* !package.json !README.md !LICENSE \ No newline at end of file diff --git a/custom.d.ts b/custom.d.ts index bbf43fb2..56b27d74 100644 --- a/custom.d.ts +++ b/custom.d.ts @@ -18,10 +18,6 @@ declare module '*.css' { declare var __REDOC_VERSION__: string; declare var __REDOC_REVISION__: string; -declare type Dict = { - [key: string]: T; -}; - interface Element { scrollIntoViewIfNeeded(centerIfNeeded?: boolean): void; } diff --git a/src/types/index.d.ts b/src/types/index.d.ts index c02a721c..8103c2ef 100644 --- a/src/types/index.d.ts +++ b/src/types/index.d.ts @@ -1,3 +1,8 @@ export * from './open-api'; export type Omit = Pick>; +declare global { + type Dict = { + [key: string]: T; + }; +}