For macs, if you're signed into the same Apple account on both, you can "share" the same keyboard and mouse across them.
It does tend to be finicky - sometimes it just refuses to connect, and won't tell me why, and sometimes it'll forget the arrangement. And it requires you to be signed into one account on two machines, which some people may not want to do on corporate laptops.
I use two computers displayed side-by-side with the picture-in-picture feature of a single ultra-wide monitor.
Input leap[0] is a great open source KVM software version of the deskhop which allows me to control both computers on the same monitor with the sam peripherals.
Well, my initial thought was that I have more cpu cycles and storage than spare desk space, so software is the easy win. But thinking about it, I do occasionally plug sbc's or liter pc's for bare metal OS installs. Deskhop might be the perfect solution for that!
I had a setup like this back in 2000 using VNC, it always used to spin people out when they realised one of my monitors was a SPARCstation and the other was a WinME box. :D
I do the same but with a usb-c dongle. For whatever reason my brain needs a hard reset when switching between tasks otherwise my productivity nose dives.
It does tend to be finicky - sometimes it just refuses to connect, and won't tell me why, and sometimes it'll forget the arrangement. And it requires you to be signed into one account on two machines, which some people may not want to do on corporate laptops.