When I create a new Next.js app via npx create-next-app@latest .
, I get the following messages
npm warn deprecated [email protected]: This module is not supported, and leaks memory. Do not use it. Check out lru-cache if you want a good and tested way to coalesce async requests by a key value, which is much more comprehensive and powerful.
npm warn deprecated @humanwhocodes/[email protected]: Use @eslint/config-array instead
npm warn deprecated [email protected]: Rimraf versions prior to v4 are no longer supported
npm warn deprecated @humanwhocodes/[email protected]: Use @eslint/object-schema instead
npm warn deprecated [email protected]: Glob versions prior to v9 are no longer supported
This does not stop me from using Next.js, but I’ve tried to add Sentry to an app via the CLI and the same messages pop up, particularly [email protected]
. I’ve tried installing the recommended packages in the messages but no luck.
Below is the package.json
file:
{
"name": "cypress",
"version": "0.1.0",
"private": true,
"scripts": {
"dev": "next dev",
"build": "next build",
"start": "next start",
"lint": "next lint"
},
"dependencies": {
"react": "^18",
"react-dom": "^18",
"next": "14.2.5"
},
"devDependencies": {
"typescript": "^5",
"@types/node": "^20",
"@types/react": "^18",
"@types/react-dom": "^18",
"postcss": "^8",
"tailwindcss": "^3.4.1",
"eslint": "^8",
"eslint-config-next": "14.2.5"
}
}
happy to upload any other info needed
I tried installing the packages recommended in the warning messages with no luck, and I’ve changed the eslint version in the package.json
file, from: "eslint": "^8"
, to: "eslint": "^9"
then running npm install
, npm install --force
and npm install --legacy-peer-deps
with no luck.
EDIT: following this thread, I switched to yarn and no longer had the error, which is curious. If anyone can explain why that is I would be so grateful!!