I'm just learning about flexbox, and I'm trying to understand how it works. I have to build a dashboard that has the width and height of the viewport ( no scroll-bar) , a fixed height header, a fixed height footer, and an auto complete height content. The content is composed from a menu with a fixed width, and a preview with an auto complete width and height;
I think this can be done only with nested flexbox like in this example: http://jsfiddle.net/03qLy6zL/9/
html
<div class="header">
</div>
<div class="content">
    <div class="menu"></div>
    <div class="preview"></div>
</div>
<div class="footer">
    footer
</div>
css
html,body {
    height: 100%;
    margin:0px;
    padding:0px;
}
body{
    display:flex;
    flex-direction:column;
}
body > * {
    flex-shrink: 0;
}
.header{
    background-color: yellow;
    height:50px;
}
.content{
    flex-grow: 1;
    display:flex;
    flex-direction:row;
}
.menu{
    background-color: tomato;
    width:300px;
    flex-grow: 0;
}
.preview{
    background-color: lightgreen;
    flex-grow: 1;
}
.footer{
    height:50px;
    background-color:lightblue;
}
Is this the best way to build this, or it can be done without nested flex boxes? Thanks
 
     
    