A new Face ID repair option for the iPhone X won't involve replacing the whole device, as reported by MacRumors. The TrueDepth Camera service option that will be provided by Apple soon will fix the face unlock feature of the 2018 and newer models, but it wasn't included in the previous models.
Repairing just the Face ID component can be difficult since it is a fairly complex system with four components. If any of these components malfunction, you could lose the face unlock feature and have to enter a password.
Apple used to swap the whole device with a refurbished replacement for broken Face ID. Customers with undamaged phones, who have an AppleCare warranty, might be okay with that. A full replacement for the iPhone X would cost $549, since most users don't have an active AppleCare warranty. There is no mention of how much the TrueDepth camera replacement would cost.
Data transfers to a new device are cumbersome for those not paying for Apple's iCloud backup subscription, and Whole unit replacements can be wasteful on the supply-chain front. In order to maintain face unlock, the screen replacement market requires the transfer of a fragile flood illuminator component and earpiece assembly to the new screen.
It was difficult to replace the screens of the latest models without losing Face ID. Since then, Apple has fixed it through a software fix and also announced a self-repair program that will give end users and third-party service providers access to parts and tools to fix screens, batteries, and cameras.