Yes, YVR has US customs & immigrations, so she'd pre-clear in Vancouver and arrive at SFO as if she were on a domestic flight.
But which airline is she booked on for each leg? It matters which terminal she lands in and departs from at SFO, as only a few terminals are connected air-side. The rest require reentering through security.