Font size extremely small on mobile devices

前端 未结 2 671
醉梦人生
醉梦人生 2020-12-03 14:07

I have a

block in a huge

in the main body of my html with 80% in font-size, and also I have a footer
相关标签:
2条回答
  • 2020-12-03 14:29

    Have you added the viewport meta tag to your document?

    If not, add this to your head section:

    <meta name="viewport" content="width=device-width, initial-scale=1">
    

    A mobile browser will naturally attempt to zoom out to display your entire web page like a desktop browser. The viewport meta tag scales your page to the device width.

    More information:

    • A tale of two viewports ~ QuirksMode.org
    • Using the viewport meta tag to control layout on mobile browsers ~ MDN
    0 讨论(0)
  • 2020-12-03 14:34

    Depending on the version of IOS you're using it may actually be an issue, with that version of the browser.

    Just declare the base font size:

    body {
     ~mybase font size
    }
    
    0 讨论(0)
提交回复
热议问题