Cross browser compatibility – which browsers should you install?
To test your code, you will need all the modern web browsers. In your list, you should have the following browsers:
- Google Chrome (newest version)
- Mozilla Firefox (newest version)
- Mozilla Firefox developers edition (newest version)
- Opera (newest version)
- Safari (newest version)
- Internet Explorer
Internet Explorer (IE) is the biggest issue in frontend developers' lives because you will need a bunch of IEs on your machine, for example, 9, 10, and 11. The list is getting smaller because back in the days the list was longer. IE6, 7, 8, 9, and so on. Now IE6, 7, and 8 are mostly not supported by the biggest web projects like YouTube and Facebook. But it sometimes occurs in big companies in which the changing of operating systems is a pretty complicated process.
To easily test your code on a bunch of browsers, it is good to use online tools dedicated for this test:
But an easy and free way to do it is to create a virtual machine on your computer and use the system and browser which you need. To collect the required versions of IE, you can refer to http://modern.ie. With modern.ie
, you can select the IE version you need and your version of virtual machine platform (VirtualBox, Parallels, Vagrant, VMware).
How to use inspector
Dealing with HTML and CSS code is almost impossible nowadays without inspector. In this tool, you can see the markup and CSS. Additionally, you can see the box model. This is well known too in browsers for web developers. A few years ago, everybody was using Firebug dedicated for Firefox. Now each modern browser has its own built-in inspector, which helps you to debug a code.
The easiest way to invoke inspector is to right-click on an element and choose Inspect. In Chrome, you can do it with a key shortcut. In Windows, you have to press F12. In MAC OSX, you can use cmd + alt + I to invoke inspector.
Key shortcuts
For faster using of your browser, it's good to know some key combinations that will speed up the process.
Key combination |
Function |
---|---|
Ctrl + R, cmd + R |
Reload |
Ctrl + Shift + R, cmd + shift + R |
Reload with cache |
cmd + I, F12 |
Inspector |
Ctrl + U, cmd + alt + U |
Source of page |