Yoast / wordpress-seo

Yoast SEO for WordPress
https://yoast.com/wordpress/plugins/seo/
Other
1.77k stars 890 forks source link

Remove redux and react/redux from all bundles #13975

Closed atimmer closed 4 years ago

atimmer commented 4 years ago

Roadmap issue: https://github.com/Yoast/roadmap/issues/137 Product owner: @jdevalk

Is your feature request related to a problem? Please describe.

Redux / React Redux are now included in multiple bundles. They should only be included once.

Describe the solution you'd like

Create a new bundle that includes react/redux and redux. Put redux and react/redux somewhere on our global (yoast.redux/yoast.reactRedux). Add redux and react/redux to the externals list, pointing to the global on which you've put these libraries.

why you think the feature request is something we should consider for the Yoast SEO plugins?

Decreased bundle size.

Additional context

You can use BUNDLE_ANALYZER=1 yarn start to run the bundle analyzer. This is useful to see whether redux is still included in the bundles.

abotteram commented 4 years ago

Fixed in https://github.com/Yoast/wordpress-seo/pull/14049