Bläddra i källkod

fix(webpack): ignore optional canvas dependency in resemblejs

Skipping node-canvas dependency in resemblejs as it [fails in certain environments](https://github.com/rsmbl/Resemble.js#nodejs).
The reference states

> If you are using Resemble.js for in-browser analysis only, you can skip the node-canvas dependency.
master
Werner Fleischer 3 år sedan
förälder
incheckning
a0aff63dde
1 ändrade filer med 4 tillägg och 0 borttagningar
  1. 4
    0
      webpack.config.js

+ 4
- 0
webpack.config.js Visa fil

294
             plugins: [
294
             plugins: [
295
                 ...config.plugins,
295
                 ...config.plugins,
296
                 ...getBundleAnalyzerPlugin(analyzeBundle, 'app'),
296
                 ...getBundleAnalyzerPlugin(analyzeBundle, 'app'),
297
+                new webpack.IgnorePlugin({
298
+                    resourceRegExp: /^canvas$/,
299
+                    contextRegExp: /resemblejs$/
300
+                }),
297
                 new webpack.IgnorePlugin({
301
                 new webpack.IgnorePlugin({
298
                     resourceRegExp: /^\.\/locale$/,
302
                     resourceRegExp: /^\.\/locale$/,
299
                     contextRegExp: /moment$/
303
                     contextRegExp: /moment$/

Laddar…
Avbryt
Spara