Complete the code to set the viewport to a mobile screen size.
cy.[1]('iphone-6')
cy.visit() instead of cy.viewport().cy.get().The cy.viewport() command sets the screen size for testing different devices.
Complete the code to set the viewport to a custom width and height.
cy.viewport({ width: [1], height: 800 })The width value must be a number without quotes to set the viewport size correctly.
Fix the error in the code to set the viewport to tablet size.
cy.viewport({ width: 768, [1]: 1024 })width twice instead of height.size or screen.The correct property for height is height, not width or others.
Fill both blanks to set the viewport to a landscape iPad size.
cy.viewport({ width: [1], height: [2] })Landscape iPad size is width 1024 and height 768 pixels.
Fill all three blanks to set the viewport to a custom size and test a page.
cy.viewport({ width: [1], height: [2] })
cy.[3]('https://example.com')click instead of visit to open the page.Set viewport width to 1280, height to 720, then visit the page with cy.visit().
