Open rmccue opened 3 years ago
I feel like this is a reasonable default considering this version of react-scripts
is geared towards WP and has a significant impact on the end bundle size. Happy to have a flag that sets it otherwise though to cover all the bases / use-cases.
and has a significant impact on the end bundle size
Users end up loading the same amount of data regardless, so it's not too big of an issue on that front.
Not if something is loading WP's version of React as well. That's really what this is addressing - the plugin use-case.
1e26dfd2b160d4b4218efed0ac0c41f7db8f0829 configured react/react-dom/moment as externals. This removes the ability for users to control these scripts, and goes against the original purpose of react-wp-scripts (for SPAs) as it introduces a hard dependency on core's version of these scripts.
(Might be worth a setting of some sort for this?)