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

infer props from overriden Component #68

Open
erickskrauch opened this issue Sep 11, 2024 · 0 comments
Open

infer props from overriden Component #68

erickskrauch opened this issue Sep 11, 2024 · 0 comments

Comments

@erickskrauch
Copy link

erickskrauch commented Sep 11, 2024

It will help with TS errors when writing something like this:

import { Link } from 'react-router-dom';
import { Button } from '@telegram-apps/telegram-ui';

<Button Component={Link} to="/route">
    Button
</Button>

In this example, the to prop isn't declared from TypeScript's point of view. But if I ignore this error, the code actually works fine.

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

1 participant