Skip to content

Commit

Permalink
Update dependency upgrades - non-major (#72)
Browse files Browse the repository at this point in the history
* Update dependency upgrades - non-major

* Create next@13.3.0.patch

* Delete next@13.2.4.patch

* Update patch path

* Update dependencies, lockfile

* Fix type error with router.push path

Ref: vercel/next.js#48099

---------

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Karl Horky <karl.horky@gmail.com>
  • Loading branch information
renovate[bot] and karlhorky committed Apr 7, 2023
1 parent a4378e1 commit a8fc247
Show file tree
Hide file tree
Showing 5 changed files with 164 additions and 243 deletions.
3 changes: 2 additions & 1 deletion app/(auth)/login/LoginForm.tsx
@@ -1,5 +1,6 @@
'use client';

import { Route } from 'next';
import { useRouter } from 'next/navigation';
import { useState } from 'react';
import { getSafeReturnToPath } from '../../../util/validation';
Expand Down Expand Up @@ -46,7 +47,7 @@ username: bob / password: def`}</pre>
const returnTo = getSafeReturnToPath(props.returnTo);

if (returnTo) {
router.push(returnTo);
router.push(returnTo as Route);
return;
}

Expand Down
16 changes: 8 additions & 8 deletions package.json
Expand Up @@ -16,23 +16,23 @@
"canvas": "2.11.2",
"cookie": "0.5.0",
"dompurify": "3.0.1",
"dotenv-cli": "7.1.0",
"dotenv-cli": "7.2.1",
"dotenv-safe": "8.2.0",
"jsdom": "21.1.1",
"ley": "0.8.1",
"next": "13.2.4",
"next": "13.3.0",
"postgres": "3.3.4",
"react": "18.2.0",
"react-dom": "18.2.0",
"react-markdown": "8.0.6",
"sass": "1.60.0",
"sass": "1.61.0",
"sharp": "0.32.0",
"tsm": "2.3.0",
"zod": "3.21.4"
},
"devDependencies": {
"@babel/eslint-parser": "7.21.3",
"@next/eslint-plugin-next": "13.2.4",
"@next/eslint-plugin-next": "13.3.0",
"@ts-safeql/eslint-plugin": "0.0.25",
"@types/bcrypt": "5.0.0",
"@types/dompurify": "3.0.1",
Expand All @@ -43,12 +43,12 @@
"@types/react-dom": "18.0.11",
"@typescript-eslint/eslint-plugin": "5.57.1",
"@typescript-eslint/parser": "5.57.1",
"@upleveled/eslint-config-upleveled": "4.0.0",
"@upleveled/eslint-config-upleveled": "4.0.7",
"@upleveled/eslint-plugin-upleveled": "2.1.6",
"eslint": "8.37.0",
"eslint-config-next": "13.2.4",
"eslint-config-next": "13.3.0",
"eslint-config-react-app": "7.0.1",
"eslint-import-resolver-typescript": "3.5.4",
"eslint-import-resolver-typescript": "3.5.5",
"eslint-plugin-cypress": "2.13.2",
"eslint-plugin-flowtype": "8.0.3",
"eslint-plugin-import": "2.27.5",
Expand All @@ -71,7 +71,7 @@
},
"pnpm": {
"patchedDependencies": {
"next@13.2.4": "patches/next@13.2.4.patch"
"next@13.3.0": "patches/next@13.3.0.patch"
}
}
}
90 changes: 0 additions & 90 deletions patches/next@13.2.4.patch

This file was deleted.

33 changes: 33 additions & 0 deletions patches/next@13.3.0.patch
@@ -0,0 +1,33 @@
diff --git a/dist/server/web/spec-extension/response.d.ts b/dist/server/web/spec-extension/response.d.ts
index 268f52b1f12c2f1bb9d71f7c51d8dd6cf3194ac8..2b6b94bd8b68338be31b89cdbee01d7e8dbee9b4 100644
--- a/dist/server/web/spec-extension/response.d.ts
+++ b/dist/server/web/spec-extension/response.d.ts
@@ -2,14 +2,15 @@ import type { I18NConfig } from '../../config-shared';
import { NextURL } from '../next-url';
import { ResponseCookies } from './cookies';
declare const INTERNALS: unique symbol;
-export declare class NextResponse extends Response {
+export declare class NextResponse<B = void> extends Response {
[INTERNALS]: {
cookies: ResponseCookies;
url?: NextURL;
+ B: B;
};
constructor(body?: BodyInit | null, init?: ResponseInit);
get cookies(): ResponseCookies;
- static json(body: any, init?: ResponseInit): NextResponse;
+ static json<T>(body: T, init?: ResponseInit): NextResponse<T>;
static redirect(url: string | NextURL | URL, init?: number | ResponseInit): NextResponse;
static rewrite(destination: string | NextURL | URL, init?: MiddlewareResponseInit): NextResponse;
static next(init?: MiddlewareResponseInit): NextResponse;
diff --git a/index.d.ts b/index.d.ts
index cba2b1dd4e056208cfc9b34af23b90095bf8a661..853c978956a9d386cf6ea22c2c9d62b9dca3e17a 100644
--- a/index.d.ts
+++ b/index.d.ts
@@ -13,5 +13,6 @@
/// <reference path="./script.d.ts" />
/// <reference path="./server.d.ts" />

+export type Route = string & {};
export { default } from './types'
export * from './types'

0 comments on commit a8fc247

Please sign in to comment.