sort foods
This commit is contained in:
+10
-13
@@ -2,11 +2,12 @@ import PreferenceWrapper from '@/components/wrapper/PreferenceWrapper'
|
||||
import React from 'react'
|
||||
import type { Metadata, Viewport } from 'next'
|
||||
|
||||
type LayoutParams = { name: string }
|
||||
|
||||
export async function generateMetadata ({
|
||||
params
|
||||
}: {
|
||||
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
||||
params: any
|
||||
params: Promise<LayoutParams>
|
||||
}): Promise<Metadata> {
|
||||
const { name } = await params
|
||||
return {
|
||||
@@ -16,21 +17,17 @@ export async function generateMetadata ({
|
||||
}
|
||||
}
|
||||
|
||||
export async function generateViewport ({}: {
|
||||
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
||||
params: any
|
||||
}): Promise<Viewport> {
|
||||
export async function generateViewport (): Promise<Viewport> {
|
||||
return {
|
||||
themeColor: '#F4F5F9'
|
||||
}
|
||||
}
|
||||
|
||||
type Props = {
|
||||
children: React.ReactElement
|
||||
}
|
||||
|
||||
function layout ({ children }: Props) {
|
||||
export default function Layout ({
|
||||
children
|
||||
}: {
|
||||
children: React.ReactNode
|
||||
params: Promise<LayoutParams>
|
||||
}): React.ReactNode {
|
||||
return <PreferenceWrapper>{children}</PreferenceWrapper>
|
||||
}
|
||||
|
||||
export default layout
|
||||
|
||||
Reference in New Issue
Block a user