From b731765c9da247e9e3351e3553975eca08b61190 Mon Sep 17 00:00:00 2001 From: Antonio Stoilkov Date: Sun, 15 Mar 2020 13:15:21 +0200 Subject: [PATCH] :bug: building doesn't work Fails with "error TS5055: Cannot write file '/Users/astoilkov/Repos/use-local-storage-state/dist/index.d.ts' because it would overwrite input file.". - https://stackoverflow.com/questions/42609768/typescript-error-cannot-write-file-because-it-would-overwrite-input-file - https://github.com/Microsoft/TypeScript/issues/16394 - https://github.com/microsoft/TypeScript/issues/27436 - https://github.com/microsoft/TypeScript/issues/14538 --- test.ts | 3 +-- tsconfig.json | 2 +- 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/test.ts b/test.ts index bf3f776..241fc37 100644 --- a/test.ts +++ b/test.ts @@ -1,6 +1,5 @@ -import useLocalStorageState from '.' import { renderHook, act } from '@testing-library/react-hooks' -import { createLocalStorageStateHook } from '.' +import useLocalStorageState, { createLocalStorageStateHook } from '.' beforeEach(() => { localStorage.clear() diff --git a/tsconfig.json b/tsconfig.json index 699a875..27f9466 100644 --- a/tsconfig.json +++ b/tsconfig.json @@ -26,5 +26,5 @@ "forceConsistentCasingInFileNames": true }, - "exclude": ["test.ts"] + "include": ["index.ts"] }