So I have a Mi Box 4k, Samsung UN40J5350 TV, and Sony DAV-DZ870W 5.1 home theatre.
The Mi Box has HDMI and 3.5/SPDIF audio out. The TV has HDMI ins and optical audio out, and the home theatre only has analogue and optical audio in (I know, it’s old, but it’s the only one I have).
Which is the correct way of connecting it all, Mi Box > HDMI to TV and TV > optical audio to home theatre?
Correct way, I'm not 100% sure that my way is the correct way but it makes for the most convenient way and it still sounds great.
I do pretty much what you said, I connect all devices via HDMI to the TV then have my TV send via optical audio. That way I don't have to worry about switching more then one input. It sucks to have to switch the input on both your TV and your surround sound.
I just looked it up though and this is some of the things I found
It really depends on what your home theater system can handle then, so lets see, yours handles
Dolby Pro Logic II, Dolby Digital, DTS. So it looks like optical from TV should be just fine for you. After looking in to this for the few minutes I did, it showed me to fully understand all the differences, it would take me a while. So just using the bit of knowledge I gained without spending more time, I would say your best bet is to use DTS for the higher bitrate.
Good luck