I keep a trash bag or 2 stuffed in the bottom of my backpack and panniers. When it might rain, I put all my stuff in it. For my more valuable stuff (phone, wallet, etc.), I keep a big zip lock bag also. The backpack and panniers get wet, but the stuff inside stay dry.
-- John