It is indeed my most favorite feature from iPhone X beside the near perfect camera phone.
Have seen some frustration in the thread, i feel you guys!! I have been finding a way to solve this until i gave up. This morning i randomly hover the internet to feed my - still curious - stage on this problem. You know what, i solved this!!
1. So i read this thread and tried out several way.
2. My setting in whatsapp : setting >> notification >> show preview OFF
3. My setting in general : setting >> notifications >> whatsapp >> sounds on badge app icon on show on lock screen on show history off show as banners off (and here is the tricky one) show preview by default is show when unlocked. Change it to never. Send some messages to whatsapp and you will find there will be names nor message preview appearing, it will only show notifications. Open whatsapp and read the message. Go back to setting and go back to notification, then you change back show preview to “when unlocked”.
Now it shows the sender name without message preview when you unlock the phone with face ID.
I think this occured because the whatsapp update and how the iOS communicating to the app. By changing it first to never show and set it back to “when unlocked” somehow reset the communication from iOS to whatsapp.
I hope it will help!