Merged in chore/update-eslint-configs (pull request #2812)
chore: Extend eslint configs from @typescript-eslint/recommended * Change to typescript recommended in scandic-web * Remove comment * Change to recommended ts config in partner-sas * Change to recommended ts lint config in booking-flow Approved-by: Linus Flood
This commit is contained in:
@@ -3,11 +3,11 @@ import type { PageContentTypeEnum } from "@scandic-hotels/trpc/enums/contentType
|
||||
|
||||
export type NextSearchParams = { [key: string]: string | string[] | undefined }
|
||||
|
||||
export type SearchParams<S = {}> = {
|
||||
export type SearchParams<S = object> = {
|
||||
searchParams: Promise<S & { [key: string]: string }>
|
||||
}
|
||||
|
||||
export type Params<P = {}> = {
|
||||
export type Params<P = object> = {
|
||||
params: Promise<P>
|
||||
}
|
||||
|
||||
@@ -50,7 +50,9 @@ export type PreviewParams = {
|
||||
live_preview?: string
|
||||
}
|
||||
|
||||
export type LayoutArgs<P = undefined> = P extends undefined ? {} : Params<P>
|
||||
export type LayoutArgs<P = undefined> = P extends undefined
|
||||
? unknown
|
||||
: Params<P>
|
||||
|
||||
export type PageArgs<P = undefined, S = undefined> = LayoutArgs<P> &
|
||||
(S extends undefined ? {} : SearchParams<S>)
|
||||
(S extends undefined ? unknown : SearchParams<S>)
|
||||
|
||||
Reference in New Issue
Block a user