Critical dependency warning
italodeandra opened this issue · 3 comments
italodeandra commented
I'm getting this warning all the time:
warn - ../node_modules/@ctrl/qbittorrent/node_modules/keyv/src/index.js
Critical dependency: the request of a dependency is an expression
scttcper commented
i think got https://github.com/sindresorhus/got uses it for caching, which we aren't using here.
scttcper commented
italodeandra commented
Thanks for the reference, but since this lib doesn't use keyv, I removed it completely from the Next application instead.
For future reference, this is my next.config.js
that also fixes the commonjs issue transpiling:
const withTM = require("next-transpile-modules")([
"@ctrl/qbittorrent",
"@ctrl/url-join",
]);
module.exports = withTM({
webpack: (config, { isServer }) => {
config.resolve.alias = {
...config.resolve.alias,
keyv: false,
};
return config;
},
});