The San Francisco Giants rode an early offensive burst to an 8-4 win over the Dodgers, spoiling Los Angeles' home opener.