In terms of security I'd assume it's better than many apps. It's a fairly important app for one of the largest companies in the world, so I'd assume they throw quite a lot of resources for security, keeping dependencies up to date, I expect them to audit any third party they depend on, they probably limit what the developer's computers can install and have access to, they probably have recurrent pen testing...
In terms of privacy though... Meta is one of the most valuable companies in the world and most of its business is serving ads, and it's way of making the ads more effective is by surveying it's potential audience (anyone with internet access) and the way they increase how many ads each is exposed to is by making their services more engaging (a.k.a. addictive), which they manage to do by surveying the users of their services. So I'd assume any opportunity they have to survey a user, they'll take it. For sure your social graph (contacts), who you talk to, when and how much and through what kind of media (text, voice, calls etc). Then probably more shady things like for example scan through the metada of all the images from your camera roll (through the access to all media files permission) to get when and where you took each picture and therefor build a location history of you. I'd assume they do that, since they put certain features behind the media access permission even when it's not needed. They might even use sensors like the accelerometer as a low-res microphone. Assume anything you give the app access to, they'll use it to survey you in some way.
But GrapheneOS can reduce the impact of many of those, thanks to contacts and file scopes and the sensors permission, so you can give WhatsApp access exclusively to what you want. I'd only give it internet access and disable everything else. They'll still monitor everything you do within the app, but at least the app won't be able to see anything else.