Repository navigation
Tell TypeScript users to install @types/three - #57
Merged
Merged
Conversation
The package's type files import the types of three, which three does not ship. A clean install of opengeometry 3.0.0 compiled with strict TypeScript fails with "Could not find a declaration file for module 'three'" until @types/three is installed. The README and the installation page now say so, as the quickstart page already did.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
The package's type files import the types of
three, whichthreedoes not ship. A clean install ofopengeometry@3.0.0, compiled with strict TypeScript, fails with "Could not find a declaration file for module 'three'" until@types/threeis installed. WithskipLibCheckthe error is hidden, and the Three.js types becomeany.The README's Installation section and the docs installation page now say to run
npm install --save-dev @types/threein a TypeScript project, as the quickstart page already did.The npm page shows the new README from the next publish.
Verification
npm run checkindocs/: format, index, strict validation and links pass.