[ts] enable "resolveJsonModule" and disable existing failures (#78855)

Co-authored-by: spalger <spalger@users.noreply.github.com>
This commit is contained in:
Spencer 2020-09-30 15:44:43 -07:00 committed by GitHub
parent 886ad8504b
commit 06d1628a00
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
31 changed files with 69 additions and 36 deletions

9
typings/index.d.ts vendored
View file

@ -35,15 +35,6 @@ declare module '*.svg' {
export default content;
}
// allow JSON files to be imported directly without lint errors
// see: https://github.com/palantir/tslint/issues/1264#issuecomment-228433367
// and: https://github.com/Microsoft/TypeScript/wiki/Breaking-Changes#arbitrary-expressions-are-forbidden-in-export-assignments-in-ambient-contexts
declare module '*.json' {
const json: any;
// eslint-disable-next-line import/no-default-export
export default json;
}
type MethodKeysOf<T> = {
[K in keyof T]: T[K] extends (...args: any[]) => any ? K : never;
}[keyof T];