Right now, the @jsweet.lang.Name annotation only can be used with:
Packages (ElementType.PACKAGE)
Methods (ElementType.METHOD)
Fields (ElementType.FIELD)
In my humble opinion, it would be fantastic if you allowed its usage with classes too. Some JavaScript programmers use class names that start with a lowercase letter, instead of an uppercase letter. This style conflicts with the typical style rules of Java. But, with this annotation, we could rename the class definitions with proper Java names.
For example, the WNumb library uses an interface called wNumbOptions. I would prefer to call it WNumbOptions in Java but, at the same time, keep its original name when transpiling it. Something like this:
@jsweet.lang.Interface
@jsweet.lang.Name (value = "wNumbOptions")
public abstract class WNumbOptions {
...
}
Hello:
Right now, the
@jsweet.lang.Name
annotation only can be used with:ElementType.PACKAGE
)ElementType.METHOD
)ElementType.FIELD
)In my humble opinion, it would be fantastic if you allowed its usage with classes too. Some JavaScript programmers use class names that start with a lowercase letter, instead of an uppercase letter. This style conflicts with the typical style rules of Java. But, with this annotation, we could rename the class definitions with proper Java names.
For example, the WNumb library uses an interface called
wNumbOptions
. I would prefer to call itWNumbOptions
in Java but, at the same time, keep its original name when transpiling it. Something like this:Thank you for your hard work :) .