As long as it's the same motherboard model (even with a different CPU if it's soldered provided you're not using a CPU-specific power management SSDT but the PlugIn method), all should work upon straight replacement and without any need to re-install macOS at all. Just make sure the replacement motherboard has same or latest BIOS version and adequate/same BIOS settings as the old one.