0

I try this simple html code with IE10.

I search a lot and most of the documents say if we want to use flex property we must use prefix (-ms-flexbox) in IE10.

But when I try this code with developer tool it works great.I have no i.e. 10 but I open the code with i.e.11 and open developer tool with f12. After that I select IE10 and it works perfect.

Any idea? Can we use flex property without prefix in IE10?

.a {
  width: 200px;
  height: 200px;
  background: red;
}

.b {
  width: 200px;
  background: orange;
}

.ww {
  display: flex;
}
<div class="ww">
  <div class="a"> 
  </div>
  <div class="b">
  </div>
</div>
Michael Benjamin
  • 346,931
  • 104
  • 581
  • 701
javauser35
  • 1,177
  • 2
  • 14
  • 34
  • 1
    You have found correctly that [a prefix is required](https://stackoverflow.com/q/18019450/11683). The IE10 compatibility mode in IE11 is not a perfect representation of the IE10 engine, [there are differences](https://gist.github.com/zachleat/5407068). – GSerg Dec 10 '17 at 15:31
  • just include for -ms-flex and regular flex because the browser takes the one it can use. I use a compiler that auto-prefixes my code and it does all of the prefixes possible, lol `display: -webkit-box; display: -moz-box; display: -ms-flexbox; display: -webkit-flex; display: flex;` Also you shouldn't worry about IE10. Not even microsoft supports that abortion anymore. – jeh Dec 10 '17 at 15:33
  • 1
    as @GSerg said, you cannot trust IE11 runing in IE10 mode, you need a genuine IE10 to really test it. I used to run different version of windows in a virtual machine with different versions of IE to have a a real render of those version. aside i did also run older versions of FF,Chrome and opera. Virtual machines allows you also to run Mac OS and test the mean Safari browser ;). Give a look at virtualbox which is free. I actually do not have IE10 set anywhere for testing. If this is for a single row without wrapping, display:table will do fine by the way.... – G-Cyrillus Dec 10 '17 at 15:48
  • https://stackoverflow.com/q/35137085/3597276 – Michael Benjamin Dec 10 '17 at 17:10

0 Answers0