Viewport is the user’s visible area of the webpage.This varies with the device.HTML 5 introduced a method to let web designer’s take control of the view port through meta tag.
<meta name="viewport" content="width=device-width, initial-scale=1.0">
- The meta viewport element gives the information needed for the browser to control the page’s dimension and scaling.
- The width=device-width sets the width of the page to follow the scree width of the device.
- The initial-scale=1.0 sets the initial zoom level of the page when it is first loaded by the browser.