diff --git a/.eslintignore b/.eslintignore
index d9fe6f26..c912533d 100644
--- a/.eslintignore
+++ b/.eslintignore
@@ -1,2 +1 @@
__tests__
-templates/next.d.ts
diff --git a/__tests__/next.d.ts b/__tests__/next.d.ts
deleted file mode 100644
index a283852f..00000000
--- a/__tests__/next.d.ts
+++ /dev/null
@@ -1,23 +0,0 @@
-import { NextResponse } from 'next/server';
-
-declare const INTERNALS: unique symbol;
-
-declare module 'next/server' {
- /**
- * Workaround to enable generic type arguments for NextResponse until
- * PR is merged:
- * https://github.com/vercel/next.js/pull/47526
- * Original issue: https://github.com/vercel/next.js/issues/45943
- */
- export class NextResponse
extends Response {
- [INTERNALS]: {
- cookies: ResponseCookies;
- url?: NextURL;
- Body?: Body;
- };
- static json(
- body: JsonBody,
- init?: ResponseInit,
- ): NextResponse;
- }
-}
diff --git a/bin/install.js b/bin/install.js
index 1b0a4ec4..5442fb9c 100755
--- a/bin/install.js
+++ b/bin/install.js
@@ -151,11 +151,6 @@ for (const {
name: templateFileName,
path: templateFilePath,
} of templateFileNamesAndPaths) {
- // Don't copy Next.js types for non-Next.js projects
- if (templateFileName === 'next.d.ts' && !('next' in projectDependencies)) {
- continue;
- }
-
// Don't copy create-react-app types for non-create-react-app / non-Next.js projects
if (
templateFileName === 'react-app-env.d.ts' &&
diff --git a/templates/.eslintignore b/templates/.eslintignore
index d081d689..0bfe7856 100644
--- a/templates/.eslintignore
+++ b/templates/.eslintignore
@@ -8,8 +8,3 @@ dist
# Next.js build folder
.next
-
-# Type overrides for Next.js
-# https://github.com/upleveled/eslint-config-upleveled/commit/0789cfa8873176a675ccde4c569a4d7c9c5f04b2
-# https://github.com/vercel/next.js/issues/45943#issuecomment-1500874994
-next.d.ts
diff --git a/templates/next.d.ts b/templates/next.d.ts
deleted file mode 100644
index a283852f..00000000
--- a/templates/next.d.ts
+++ /dev/null
@@ -1,23 +0,0 @@
-import { NextResponse } from 'next/server';
-
-declare const INTERNALS: unique symbol;
-
-declare module 'next/server' {
- /**
- * Workaround to enable generic type arguments for NextResponse until
- * PR is merged:
- * https://github.com/vercel/next.js/pull/47526
- * Original issue: https://github.com/vercel/next.js/issues/45943
- */
- export class NextResponse extends Response {
- [INTERNALS]: {
- cookies: ResponseCookies;
- url?: NextURL;
- Body?: Body;
- };
- static json(
- body: JsonBody,
- init?: ResponseInit,
- ): NextResponse;
- }
-}
diff --git a/templates/tsconfig.json b/templates/tsconfig.json
index f50b3d36..0fdf2e40 100644
--- a/templates/tsconfig.json
+++ b/templates/tsconfig.json
@@ -16,7 +16,6 @@
"**/*.jsx",
"**/*.cjs",
"**/*.mjs",
- ".next/types/**/*.ts",
- "next.d.ts"
+ ".next/types/**/*.ts"
]
}