Replies: 2 comments 4 replies
-
We've supported but the type was missing, this is fixed in 13.2.3 |
Beta Was this translation helpful? Give feedback.
4 replies
-
we should add the below code into app/layout.tsx import type { Viewport } from "next";
export const viewport: Viewport = {
// width: 'device-width',
// initialScale: 1,
// maximumScale: 1,
// userScalable: false,
viewportFit: 'cover',
} |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Describe the feature you'd like to request
With the new Metadata API on 13.2, you can customised the following properties for the viewport metadata:
So apart from the options listed above, there's currently no other way to add or customise additional properties, such as
viewport-fit
for example.The
viewport-fit=cover
property is particularly useful in allowing websites to span the whole screen, including the device’s sensor housing or notch area. Of course, additional CSS can be applied to add inset padding that respects the device's safe area. You could not, however, add this property with the current implementation.Describe the solution you'd like
Add
viewport-fit
as one of the available options that can be customised for the meta viewport tag.Describe alternatives you've considered
-
Beta Was this translation helpful? Give feedback.
All reactions