Review main Merged

88388[TASK] Simplify contrib package bundling

Benjamin Franzke CR +2 V +2 Hard +183 −283 updated 03/05/25, 08:21

Commit message

Use native ESM (ECMAScript modules) sources for alwan, mark.js and
flatpickr instead of wrapping them in a CommonJS-to-ESM closure.

Our custom wrappers are no longer needed, as upstreams started to
ship modern ESM sources, next to the traditional CommonJS sources.

Also streamline repetitive rollup configs into a generalized build
helper, as mark.js and flatpickr are now processed by rollup
and their configs would have been very identical to the existing
per-library configs, which were already duplicated multiple times
before.
These libraries now share a bundle helper with some automagic
to resolve the ESM sources via the module related entry point
"exports" [1] or de facto standard "module" fields in package.json.

While at it, the CKEditor translation generation is streamlined
to be a simple rollup pipeline, without the need for intermediate files
in Build/ckeditorLocales/ and without build logic beeing spread between
some grunt scripts and rollup.
Also some outdated CKEditor workarounds are removed from the rollup
configuration as well.

[1] https://nodejs.org/api/packages.html#main-entry-point-export

Review

  • Code review CR +2 Done
    • Benjamin Franzke +2
    • Andreas Kienast +1
    • Benni Mack +1
  • Verified V +2 Done
    • Benjamin Franzke +2
    • Andreas Kienast +1
    • Benni Mack +1
    • core-ci +1 CI

Issues 2

Files 22

Review log 913

  1. Benjamin Franzke uploaded patch set 1 02/27/25, 19:56

  2. core-ci voted on patch set 1 V +1 02/27/25, 20:02 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/74844

  3. Benjamin Franzke uploaded patch set 2 V +1 02/27/25, 23:07

  4. core-ci voted on patch set 2 V +1 02/27/25, 23:16 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/74850

  5. Benjamin Franzke uploaded patch set 3 V +1 02/28/25, 07:00

  6. core-ci voted on patch set 3 V +1 02/28/25, 07:06 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/74865

  7. Benjamin Franzke uploaded patch set 4 V +1 02/28/25, 08:30

  8. Benjamin Franzke updated the commit message in patch set 5 02/28/25, 08:32

  9. core-ci voted on patch set 5 V +1 02/28/25, 08:38 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/74873

  10. Benni Mack voted on patch set 5 CR +1 V +1 03/04/25, 12:05

  11. Andreas Kienast voted on patch set 5 CR +1 V +1 03/05/25, 07:56

  12. Benjamin Franzke voted on patch set 5 CR +2 V +2 03/05/25, 07:59

  13. Benjamin Franzke merged patch set 6 03/05/25, 08:21