Since pull-up is enabled by setting the output to 1 while pin is configured as an input, you will be fine here.
But lets say you had no pull-up or pull-down, just a floating input (or external pull-up), so the output buffer was set to 0. This is not a problem since direction is configured as an input. But then you change it to an output which is high.
If you set the high level first, then it still would not matter, since the pin is still an input, so when you switch the direction, it will just cleanly go to "1".
On the other hand if you set the direction first, then the output will go to 0 before MCU get to setting the output value high.
Same principle applies to PMUX settings. You always want to configure and enable the peripheral before setting the PMUX.