Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

BUGFIX: Neos 8.3 plugins dont lower yield in plugins #3604

Merged

Conversation

mhsdesign
Copy link
Member

@mhsdesign mhsdesign commented Aug 30, 2023

Resolves: #3470

This resolves a regression from the EsBuild change in 8.2 as we removed the polyfills (polyfill.js) and thus also the regenerator runtime polyfill (import 'regenerator-runtime/runtime';). We removed the polyfills as we were from then on targeting only modern Browsers (at least ES2020) but i didnt think of the fact that build plugins might transpile down to an older es version and thus require regeneratorRuntime.

The problem is obscured because other older Neos Ui Plugins might already ship the global regeneratorRuntime and then other plugins can profit from this invisible dependency and work. But as soon as no other plugin is installed anymore or the settings loading order changes (due to a deployment on another unix system where settings might be picked up in a different order) your plugin might stop working.

Plugins using the modern webpack extensibility (v8.2 or 8.3) should simply at no time build plugins which require the legacy regeneratorRuntime. This should be the default - and its currently not.

Removing the babel-plugin-transform-regenerator from our webpack config works and doesnt transform the code. yield stays a js-generator and will not be rewritten to a state machine which depends on regeneratorRuntime.

What I did

How I did it

How to verify it

@github-actions github-actions bot added Bug Label to mark the change as bugfix 8.3 labels Aug 30, 2023
Copy link
Member

@Sebobo Sebobo left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fine by reading

@markusguenther markusguenther merged commit 1db2cdd into 8.3 Dec 16, 2023
3 checks passed
@markusguenther markusguenther deleted the bugfix/3470-neos-83-plugins-dont-lower-yield-in-plugins branch December 16, 2023 19:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
8.3 Bug Label to mark the change as bugfix
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants