Why does display: -ms-flex; -ms-justify-content: center; not work in IE10?

user2590633 picture user2590633 · Jul 17, 2013 · Viewed 67.5k times · Source

Why doesn't the following code work in IE10?

.foo {
    display: -ms-flex; 
    -ms-justify-content: center;
}

What do I need to write in order for them to work?

Answer

cimmanon picture cimmanon · Jul 17, 2013

IE10 implemented the Flexbox draft from March 2012. Those properties correspond to these:

.foo {
    display: -ms-flexbox;
    -ms-flex-pack: center;
}