Closed ptbrowne closed 6 years ago
As long as cozy-client-js is still usable in a "simple" vanilla app without any dependency, we may remove it.
Minute of meeting (@enguerran et @ptbrowne) :
babel-polyfill
pouvait amener à des bugs, il a viré babel-polyfill
et a plus ou moins cargo culté l'ajout d'un transform-runtime
dans https://github.com/cozy/cozy-bar/pull/113 via https://github.com/CPatchane/create-cozy-app/blob/master/packages/babel-preset-cozy-app/index.jsbabel-polyfill
de la lib car babel-polyfill
est déjà chargée par cozy-drive
cozy-client-js
servie par la stack ou inclue dans les imports de cozy-drive
, c'est que dans le 2e cas, on passe par une babel-loader
qui doit faire des trucs pour pas que ça pète.polyfill
n'est présent lors du runtime, la console log regeneratorRuntime is not defined
, par ailleurs :
babel-polyfill
dans cozy-drive, c'est okbabel-polyfill
dans cozy-client-js, c'est ok
Following https://github.com/cozy/cozy-bar/pull/113 where we had a problem importing twice babel-polyfill in the context of an app (1st via cozy-client, 2nd via cozy-bar), we removed
babel-polyfill
from the cozy-bar. Do we need to do the same in cozy-client ? Would it be better to import polyfills via babel-preset-env (in our case via babel-preset-cozy-app) ?I post this issue here so I do not forget, this is not an immediate bug. ping @CPatchane