💻
How are you using Babel?
Other (Next.js, Gatsby, vue-cli, ...)
Input code
class A {
static
foo = 2
}
Configuration file name
No response
Configuration
No response
Current and expected behavior
When the typescript plugin is enabled we parse that class as having a field named static and one named foo. When it's not enabled, we parse it as a class having a static field named foo.
The second behavior is correct, and enabling the TS plugin should not change it.
Environment
Babel 7.25.0
Possible solution
No response
Additional context
No response
💻
How are you using Babel?
Other (Next.js, Gatsby, vue-cli, ...)
Input code
Configuration file name
No response
Configuration
No response
Current and expected behavior
When the
typescriptplugin is enabled we parse that class as having a field namedstaticand one namedfoo. When it's not enabled, we parse it as a class having a static field namedfoo.The second behavior is correct, and enabling the TS plugin should not change it.
Environment
Babel 7.25.0
Possible solution
No response
Additional context
No response