-
-
Notifications
You must be signed in to change notification settings - Fork 1.6k
Closed
Labels
type-tech-debtTechnical debtTechnical debt
Description
Description
Follow-up to
Improve our TypeScript configuration
Skip declaration files from our dependencies
Reduce remaining static type errors
Begin path to fixing remaining (ts|tsx) errors
Screenshots
Before (670 errors)
Line 51 in b1877f3
| "skipLibCheck": false /* Skip type checking of declaration files. */ |
After (556 errors)
# skipLibCheck
- false
+ trueTo Reproduce
After
Fix JavaScript static type errors #5879 is merged- Fix 18 JS type errors for TSC to output 683 TS/TSX errors #5975 is merged
yarn tsc # locally
tsc # globallyExpected behavior
Reduced type errors excluding declaration files from our dependencies (node_modules)
Technical Details
Avoid cases of duplicate identifiers between global types in React Native vs Node
Suited to fuller repo's with more libraries
Next
- Exclude type checking remaining TS files from remaining libs (node_modules)
- Downgrade TypeScript to current ESLint-compat version (4.4.4)
- Fix remaining type errors
- TS check isn't working #4605 (CI + pre-commit)
- Extend official React Native @tsconfig base
- Upgrade ESLint for TypeScript 5
- Upgrade to TypeScript 5
- Fix husky pre-commit hook running lint-staged (should run
yarn lintnot `eslint)
References
- https://consensys.slack.com/archives/G1L7H42BT/p1677193361291439
- https://consensys.slack.com/archives/C02U025CVU4/p1677256019459879
- https://www.typescriptlang.org/tsconfig#target
- https://github.com/tsconfig/bases#react-native-tsconfigjson
- https://www.typescriptlang.org/tsconfig#skipLibCheck
- leotm/react-native-template-new-architecture@a21b7b6
- tsconfig/bases@6375cbe
- Use TypeScript by default for new applications facebook/react-native#35165
Severity
- Is this tech debt? ✅
cc @Cal-L @gantunesr
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
type-tech-debtTechnical debtTechnical debt

