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

SWC Incorrect parsing of nested <> generics in fat arrow functions #30456

Closed
mateusmirandaalmeida opened this issue Oct 27, 2021 · 3 comments · Fixed by #30619
Closed

SWC Incorrect parsing of nested <> generics in fat arrow functions #30456

mateusmirandaalmeida opened this issue Oct 27, 2021 · 3 comments · Fixed by #30619
Labels
bug Issue was opened via the bug report template.

Comments

@mateusmirandaalmeida
Copy link

mateusmirandaalmeida commented Oct 27, 2021

What version of Next.js are you using?

12.0.1

What version of Node.js are you using?

v16.6.1

What browser are you using?

Chrome

What operating system are you using?

Windows

How are you deploying your application?

Vercel

Describe the Bug

when updating the next from 11 to 12 it starts to have problem compiling generic parameters

Expected Behavior

Error: error: Unexpected token <T>. Expected jsx identifier

To Reproduce

create a simple class that receives something generic

class MyClass<T> {};

@mateusmirandaalmeida mateusmirandaalmeida added the bug Issue was opened via the bug report template. label Oct 27, 2021
@lucaskolecha
Copy link

I have the same problem, I tried to look for a solution, but so far I haven't been able to. I'm really looking forward to being able to upgrade to version 12. but with this problem I won't be able to.

@MrWangJustToDo
Copy link

same error

@balazsorban44
Copy link
Member

This issue has been automatically locked due to no recent activity. If you are running into a similar issue, please create a new issue with the steps to reproduce. Thank you.

@vercel vercel locked as resolved and limited conversation to collaborators Jan 27, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug Issue was opened via the bug report template.
Projects
None yet
4 participants