12.0.0-alpha.1
Pre-release
Pre-release
·
873 commits
to master
since this release
🚀 New Feature
- Allow
@directiveon functions for emitting function level directive code (let serverAction = @directive("'use server'") (~name) => {...}). #6756 - Add
rewatchto the npm package as an alternative build tool. #6762 - Throws an instance of JavaScript's
new Error()and adds the extension payload forcauseoption. #6611 - Allow free vars in types for type coercion
e :> t. #6828 - Allow
privatein with constraints. #6843 - Add regex literals as syntax sugar for
@bs.re. #6776 - Improved mechanism to determine arity of externals, which is consistent however the type is written. #6874 #6881 #6883
💥 Breaking Change
- Make
jandjsallowed names for tag functions. #6817 lazysyntax is no longer supported. If you're using it, useLazymodule orReact.lazy_instead. #6342- Remove handling of attributes with
bs.prefix (@bs.as->@asetc.). #6643 - Remove obsolete
@bs.openfeature. #6629 - Drop Node.js version <18 support, due to it reaching End-of-Life. #6429
- Remove deprecated -bs-super-errors option. #6814
- Some global names and old keywords are no longer prefixed. #6831
- Remove ml parsing tests and conversion from
.mlto.resvia format. #6848 - Remove support for compiling
.mlfiles, and general cleanup. #6852 - Remove
rescript convertsubcommand. #6860 - Remove support for
@bs.send.pipe. This also removes all functions inJs_typed_arraythat rely on@bs.send.pipe. #6858 #6891 - Remove deprecated
Js.VectorandJs.List. #6900
🐛 Bug Fix
- Fix unhandled cases for exotic idents (allow to use exotic PascalCased identifiers for types). #6777 #6779 #6897
- Fix unused attribute check for
@as. #6795 - Reactivate unused attribute check for
@int. #6802 - Fix issue where using partial application
...can generate code that usesCurryat runtime. #6872 - Avoid generation of
Currywith reverse application|>. #6876 - Fix issue where the internal ppx for pipe
->would not use uncurried application in uncurried mode. #6878
🏠 Internal
- Build with OCaml 5.2.0. #6797
- Convert OCaml codebase to snake case style. #6702
- Fix
-nostdlibinternal compiler option. #6824 - Remove a number of ast nodes never populated by the .res parser, and resulting dead code. #6830
- Remove coercion with 2 types from internal representation. Coercion
e : t1 :> t2was only supported in.mlsyntax and never by the.resparser. #6829 - Convert
caml_formatandjs_mathto.res. #6834 - Convert
js.mlfiles to.res. #6835 - Remove old
.mltests. #6847 - Make compiler libs ready for uncurried mode. #6861
- Make tests ready for uncurried mode. #6862
- Make gentype tests uncurried. #6866
- Remove
@@uncurried.swap, which was used for internal tests. #6875 - Build the compiler libraries/tests in uncurried mode. #6864
- Ignore
-uncurriedcommand-line flag. #6885 - Cleanup: remove tracking of uncurried state in parser/printer. #6888
- Remove
%opaqueprimitive. #6892 - Reunify JsxC/JsxU -> Jsx etc. #6895
- Remove the transformation of
foo(1,2)intoJs.Internal.opaqueFullApply(Internal.opaque(f), 1, 2), and change the back-end to treat all applications as uncurried. #6893
💅 Polish
- Make the
--helparg be prioritized in the CLI, so correctly prints help message and skip other commands. #6667 - Remove redundant space for empty return in generated js code. #6745
- Remove redundant space for export in generated js code. #6560
- Remove redundant space after continue in generated js code. #6743
- Remove empty export blocks in generated js code. #6744
- Fix indent for returned/thrown/wrapped in parentheses objects in generated js code. #6746
- Fix indent in generated js code. #6747
- In generated code, use
letinstead ofvar. #6102 - Turn off transformation for closures inside loops when capturing loop variables, now that
letis emitted instead ofvar. #6480 - Improve unused attribute warning message. #6787
- Remove internal option
use-stdlibfrom build schema. #6778 - Fix
Js.Types.JSBigIntpayload to use nativebiginttype. #6911 - Deprecate
%externalextension, which has never been officially introduced. #6906