dynamic-cdn-webpack-plugin icon indicating copy to clipboard operation
dynamic-cdn-webpack-plugin copied to clipboard

Manually script injections order.

Open sultan99 opened this issue 5 years ago • 2 comments

Is there a way to tell the plugin the order of script injections in index.html?

react-redux has peer/optional dependency - react-dom but it is not declared in package.json. Sometime (randomly) the react-redux is being injected before the react-dom by dynamic-cdn-webpack-plugin and cause exceptions.

I have asked to add react-dom in optional dependency and even sent PR but it was refused.

sultan99 avatar May 10 '19 17:05 sultan99

Hi @sultan99

Thank you for reporting this issue

Two solution here:

  • your solution: add an options to order urls (open to API suggestion)
  • add a field on module-to-cdn that override the peer-dependencies

mastilver avatar Jun 06 '19 11:06 mastilver

@mastilver you mean to add this feature? Will you accept my PR?

sultan99 avatar Jun 06 '19 12:06 sultan99