parseQuery() will be replaced with getOptions() in the next major version of loader-utils

做webpack打包時看見此錯誤訊息,也不知道是哪裡出問題,

(node:36968) DeprecationWarning: loaderUtils.parseQuery() received a non-string value which can be problematic, see https://github.com/webpack/loader-utils/issues/56
parseQuery() will be replaced with getOptions() in the next major version of loader-utils.

並非webpack prod錯誤,而是套件太舊,查一下package.json以為是loader.utils.

結果node_module沒有這套件上查了,是babel-loader這套件。

跳出這錯誤是我用6.x.x版本,直接升級上去會到8.x.x版本,又會跳出babel-core的問題,

所以我改成指定 7.x.x版本

 

Reference

https://github.com/babel/babel-loader/issues/392

發佈留言

發佈留言必須填寫的電子郵件地址不會公開。 必填欄位標示為 *