My “go to” desktop browser for doing web development is the Chrome browser. It’s got lots of cool plugins, and doesn’t crash as often as Firefox does (for me, at least).
However, it has one annoying problem for people like me who do responsive web development: It won’t resize down to 320 pixels wide, the width of an iPhone. With my Chrome browser on Windows, the minimum width is over 400px. On Mac, the minimum is 400px. This makes it a pain to quickly check mobile layouts during development. You can’t make the Chrome browser window thin enough!
Firefox, on the other hand, will get as thin as I need it to! But, It’s inconvenient to have to use two different browsers during development.
The solution is to create a browser window with no frills; no menu bar, no status bar, etc. I don’t know how to create this other than by JavaScript, however. So, I made a quick script that does it. Just type in your URL, and it will launch in a 320px wide browser window!
This works on Chrome for Mac and Windows. During development, I launch this once, and refresh it using the F5 key.
Hope you find this useful!! – Brian
In the developer window, top left, there’s a mobile icon next to the “search” icon. Use it to toggle in and out of “Device Mode”. There you can shrink the screen as much as you want, while keeping the Developer window as large as you need.
I just found it, and it’s really neat :)
https://developer.chrome.com/devtools/docs/device-mode
HI Wagedu,
Ah, yes, thanks for pointing that out!
Brian
The ‘mobile icon’ works a treat. I love toggling through the various models.
It seems iPhones up to 5S, and Galaxy phones up to S4, seem to have 320px as their narrowest width.
I feel that most of the custom @media divs I make in CSS are attributed to these ‘320’ screens.
Fortunately the later models aren’t as narrow.
Great thread and post, thanks :)
Very nice thanks! This will be helpful while taking my many screen shots for testing.
Now for your next trick, highlight in red any items that extend past the viewport and are responsible for the need to horizontally scroll.
Hi Justin,
Yeah, I’ve had to deal with that problem myself. Sometimes Chrome developer tools is helpful for finding those.
Brian
Even easier, you can just move the developer console to the right (but it still has to be in the same window) and then you can shrink the screen as much as you want in Chrome, there’s no longer a 400 pixel minimum. Just click and hold the screens icon (to the left of the X) in the console top bar and then select the other option.
Thanks for the tip Robert! – Brian
Genius. Thanks
Very informative post in these days mobiles become the most important part of our lives. It makes our lives easy we can easily talk to any person all around the world. Mobile hardware characteristics are very different as compared to laptop and desktop computers. We can get a lot of online unique mobile sites that are a perfect fit for our businesses.