A remote machine might not be always possible, such as when you develop mobile apps or when you have more than one monitor available. Sadly all options have problems. And (auto) pushing is not an option when you work on a team project where pushing non compilable code is not a welcome option.
They might work, but then one is bound to be online. Also different computers might have different configurations and that is something to pay attention to as well. Alternative is a synchronisation to source (nextcloud sounds a good fit) but then you might bump to synchronisation conflicts and such. Both ways will produce a lot of traffic unless you redirect creation of build artifacts to a local directory. Which might not be always possible.