Streaming live at 10am (PST)

Best practice for dashboard side menu

Hello all! How would you go about creating a side menu that is, say, 300px wide? Think about a traditional dashboard style page.

The way I did it, which I feel uncomfortable with, is by making the menu position “fixed”. The problem with that is the page content goes underneath the menu, forcing me to give the page content wrapper a left margin of 300px (which I am not too stoked about).

Another way I thought of doing it is wrapper everything in a flex container, which I haven’t tried, but I thought I would ask if there is a standard process to doing this sort of thing.

Both are perfectly fine. Since you got full control over the markup I would use flexbox.

In WP where I used childthemes and didn’t have access to the html markup I used fixed and margin left.