I was using the wrong hook the entire time and I only realised this now. I saw
this in the hooks documentation and I tried it out only to have it work on the
first turn. Truly incredible.
Thanking phil.catalyst from #emacs for suggesting this fix!
This should make it so modules on the right-hand side of the modeline doesn't
cut itself off. Usually, an Emacs server started won't have a GUI, so
doom-modeline doesn't actually know its width. Refreshing doom-modeline when
a new frame is created will make it aware of its width from (re)initialisation.