Closed
Description
I diffed the JS output from 9.1.4 to the output from the current master for one of our projects and noticed the following changes:
- 1. Some superfluous newlines are gone 👍
- 2. Superfluous returns (for functions returning
unit
) are gone. 👍 - 3. Output for template string literals is now different. If the template string literal starts/ends directly with a placeholder, a leading
"" +
/ trailing+ ""
is added. - 4. Promise handling is different, instead of
promise.then(f)
there is nowJs_promise.then(f, promise)
, similarly forcatch
. This is normal because of the deprecation of@bs.send.pipe
. Bindings in t-first style do not have this. - 5.
There are now some unnecessary variables generated, e.g.:(fix merged in master) - 6. The printer now adds a newline after a switch case with braces (which are redundant anyway).
- 7.
String.length
not inlined anymoreString.length
not inlined in v10 #5480 (legit as strings are now unicode)
Metadata
Metadata
Assignees
Labels
No labels