github melange-re/melange 3.0.0-v51

latest releases: 4.0.0-52, 4.0.0-51, 4.0.0-414...
4 months ago


  • BREAKING: remove Belt as a dependency of Stdlib
    • Melange no longer includes the melange.belt library by default; after
      this release, you need to add (libraries melange.belt) to your melange
  • Melange Runtime / Stdlib: remove deprecated modules and functions
    • Js.List: use Stdlib.List or Belt.List instead;
    • Js.Null_undefined: use Js.Nullable instead;
    • Js.Option: use Stdlib.Option or Belt.Option instead;
    • Js.Result: use Stdlib.Result or Belt.Result instead;
    • Js.Cast.
    • remove support for @bs / @bs.* attributes; Melange users should now
      use [@u] for uncurried application and [@mel.*] as the prefix for the
      FFI attributes (#818)
    • remove [@@mel.val], which was redundant in the Melange FFI
  • BREAKING(runtime): rename a few keys with legacy names
    1. Exception ID RE_EXN_ID to MEL_EXN_ID
    2. BS_PRIVATE_NESTED_SOME_NONE option marker to
  • BREAKING(runtime): unify pipe-first / pipe-last libraries in Js modules
    • Modules ending with 2 (e.g. Js.String2, Js.Array2,
      Js.TypedArray2) are no longer available in Melange
    • The functions in their corresponding modules now take labeled arguments
      and one positional argument, prioritizing the usage of |> but still
      allowing |. (-> in Reason) when optionally labeled arguments aren't
  • BREAKING(runtime): remove deprecated functions from Js.* modules
  • Consistently handle empty payloads in externals:
  • Fix crash when pattern matching in the presence of complex constant inlining
  • Support renaming modules in the output JS with
  • Support in @mel.obj labelled arguments
  • Fix error location for empty string interpolation in {j| .. |j}
  • Add Js.Obj.assign to merge 2 JS objects immutably
  • Turn off warning 20 (ignored-extra-argument) for %mel.raw application
  • Deprecate non-namespaced FFI attributes such as @string or @obj in favor
    of e.g. @mel.string and @mel.obj
  • Improve error messages returned by melange.ppx
  • Improve error messages in the Melange compiler core
  • Fix a typo in Node.node_module (pa{r,}rent)
  • BREAKING(runtime): Remove Js.null_undefined in favor of Js.nullable
  • BREAKING(ppx): disallow attribute payload in [] in favor of the
    external primitive string
  • Don't process [@mel.config] twice
  • BREAKING(ppx): remove @mel.splice in favor of @mel.variadic
  • Introduce an unprocessed alert to detect unprocessed Melange code, hinting
    users to preprocess with melange.ppx
  • Implement more Stdlib functions in modules String, Bytes, Buffer, BytesLabels
    and StringLabels (#711,
  • BREAKING(runtime): Improve Js.Int and change some of its functions to
    pipe-last (#966)
  • BREAKING(runtime): Improve Js.Date and change some of its functions to
    pipe-last (#967)
  • BREAKING(runtime): Improve Js.Re and change some of its functions to
    pipe-last (#969,
  • BREAKING(runtime): Improve docstrings in the Node library and change some
    of its functions to pipe-last
  • BREAKING(runtime): Improve Js.Float and change some of its functions to
    pipe-last (#968)
  • BREAKING(runtime): Remove unnecessary unit argument from Js.Math.atan2
  • BREAKING(runtime): Add labeled arguments to the callbacks in Js.Global
  • BREAKING(runtime): Add a label to's function argument pipe-last
  • runtime(Js.String): deprecate anchor, link and substr functions to
    match the JS standard deprecations
  • Fix error messages related to [@mel.meth] arity mismatches
  • ppx: split [@@deriving abstract] into two:
    • [@@deriving jsProperties] derives a JS object creation function that
      can generate a JS object with optional keys (when using [@mel.optiona])
    • [@@deriving getSet] derives getter / setter functions for the JS object
      derived by the underlying record.
  • ppx: Deprecate [@@deriving abstract]
  • BREAKING(dom): remove Dom.Storage2 in favor of Dom.Storage
  • playground: fix reporting of PPX alerts
  • Move the unicode string transformation to the compiler core so that it runs
    after PPX preprocessing
    • PPXes will no longer see the internal *j delimiter in unicode strings
      and can hook on either j or js
  • Preserve unicode in format strings
  • Support in %mel.obj
  • Upgrade the Melange JS parser to Flow

  • fix: add a newline after %mel.raw expressions to avoid breaking JS output
    when they contain single line comments
  • BREAKING(core): only allow strings in {j| ... |j} interpolation

Don't miss a new melange release

NewReleases is sending notifications on new releases.