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

[Example NextJS] The inferred type of 'default' cannot be named without a reference #56

Closed
mshd opened this issue Jul 9, 2022 · 3 comments

Comments

@mshd
Copy link

mshd commented Jul 9, 2022

./src/pages/api/[...trpc].ts:6:1
Type error: The inferred type of 'default' cannot be named without a reference to '.pnpm/next@12.2.0_beenoklgwfttvph5dgxj7na7aq/node_modules/next'. This is likely not portable. A type annotation is necessary.

4 |
5 | // Handle incoming OpenAPI requests
6 | export default createOpenApiNextHandler({
| ^
7 | router: appRouter,
8 | createContext,
9 | });

@mshd
Copy link
Author

mshd commented Jul 9, 2022

Fixed after changing "trpc-openapi": "0.2.1-alpha.0", to "trpc-openapi": "0.1.2",

@jlalmes
Copy link
Owner

jlalmes commented Jul 11, 2022

I'd accidentally tagged the 0.2.1-alpha.0 development release as latest. (As you mentioned above) please ensure you are using trpc-openapi@^0.1.3 & let me know if you are having any further issues!

@jlalmes jlalmes closed this as completed Jul 11, 2022
@mshd
Copy link
Author

mshd commented Jul 11, 2022

Yes, you should probably continue with 0.2.2 since everyone will get the 0.2.1-alpha now

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