By default, JSweet generates arrow functions for Java lambda (the 'this'
semantics is closer to Java). Wrapping a function in $noarrow will force
JSweet to produce a plain old JavaScript function rather than an arrow
function.
@Ambient annotation was used to inline declarations. However they suffer
from the Java packages structure, which is less flexible than namespaces
in TypeScript. Since @Ambient are always defined in the package they
appear, they are not convenient when working out of the root package.
Plus, now that def.* packages are working well in version 2, the
@Ambient annotation is redundant with using def.* packages. So, it was
decided that all ambient declarations should be defined in def.*
packages, thus forcing the developers to cleanly separate the actual
implementation from the bridges to external libraries. We believe it is
good practice to do so in Java in order to have a better-structured
program.
- support for decorators (fixed#43)
- added support for core JS features (function-scope this ($this),
function-scope arguments, ...
- added/modified macros ($insert, $loose/$strict, ...)
- modified es5 and es6 API to simplify the use of JavaScript strings and
arrays