Skip to content
This repository has been archived by the owner on Jun 14, 2021. It is now read-only.

Could not find declaration file for the module? #21

Open
punkscience opened this issue Feb 28, 2019 · 1 comment
Open

Could not find declaration file for the module? #21

punkscience opened this issue Feb 28, 2019 · 1 comment

Comments

@punkscience
Copy link

punkscience commented Feb 28, 2019

Could not find a declaration file for module 'react-scroll-box'. '...node_modules/react-scroll-box/target/out/index.js' implicitly has an 'any' type.
Try npm install @types/react-scroll-box if it exists or add a new declaration (.d.ts) file containing declare module 'react-scroll-box';ts(7016)

Seems to have installed fine but my project can't seem to find the type? Any suggestions. I am not having issues with any other installed packages.

This error is appearing on the line:

import {ScrollBox, FastTrack} from 'react-scroll-box'; // ES6

@punkscience
Copy link
Author

Turns out this was a red herring -- the real issue is that FastTrack is actually FastTrackMode so the example in the instructions/readme is wrong. Use FastTrackMode.PAGING

In either case, it now compiles and runs but unfortunately, no scroll box is visible.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant