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

Theme type import error #1

Open
minuscoca opened this issue Dec 23, 2021 · 0 comments · May be fixed by #2
Open

Theme type import error #1

minuscoca opened this issue Dec 23, 2021 · 0 comments · May be fixed by #2

Comments

@minuscoca
Copy link

Cannot auto complete theme when using makeStyles due to the Theme type of react-native-paper import from the wrong path.

Example:

const useStyles = makeStyles((theme, props) => ({
  screen: {
    flex: 1,
    backgroundColor: theme.colors.background,
  },
}))

Error from dev server:

src/index.tsx:3:28 - error TS2307: Cannot find module 'react-native-paper/lib/typescript/src/types' or its corresponding type declarations.

3 import type { Theme } from 'react-native-paper/lib/typescript/src/types';
@minuscoca minuscoca linked a pull request Dec 23, 2021 that will close this issue
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

Successfully merging a pull request may close this issue.

1 participant