This repository has been archived by the owner on Mar 4, 2020. It is now read-only.
Simple project config results in typescript compilation error "Could not find a declaration file for module 'lodash'" #2259
Labels
vsts
Paired with ticket in vsts
Bug Report
Importing the package and using it in a basic typescript app results in the typescript error
Could not find a declaration file for module 'lodash'
.This error can be fixed if you manually install
@types/lodash
(by runningyarn add @types/lodash -D
). However, for a good developer experience, this shouldn't be necessary - (perhaps@types/lodash
should be among the dependencies of the package, or included through some other build mechanism).Steps
I've made a sample repo that demonstrates the issue - repo steps are in the README there.
To reproduce from scratch, here are the high-levels steps.
fluent-ui-react
to the project.Expected Result
TSC should compile without warnings.
Actual Result
Version
0.43.0
Testcase
See the sample repo I created.
I investigated creating a sample on codesandbox.io, but it appears that they use react-scripts to do the compilation, which won't check (I think) for errors in npm packages the way that
tsc
does.The text was updated successfully, but these errors were encountered: