Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

How to use with typescript project (like NextJs) ? #128

Open
diego3 opened this issue Sep 17, 2021 · 1 comment
Open

How to use with typescript project (like NextJs) ? #128

diego3 opened this issue Sep 17, 2021 · 1 comment

Comments

@diego3
Copy link

diego3 commented Sep 17, 2021

Hello guys, thanks for this amazing lib.

I'm trying to use react-mic with a NextJs + Typescript project

But seams like react-mic is not ready to work with Typescript, is that right?

import { ReactMic } from 'react-mic'

------ 
import doens't work and in my vscode react-mic part is red with a message saying "Could not find a declaration file for module 'react-mic'. "

I've added react-mic as a dependency with a command:

yarn add react-mic

Everything compiled successfully, but the error is happening at runtime

@hackingbeauty
Copy link
Owner

Right, TypeScript is a Javascript npm package. I'm not going to be supporting TypeScript, but you can fork the library and create a version of it that works with TypeScript :)

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

No branches or pull requests

2 participants