After dominating the opening stages, Lawrence Shankland found Vargas with a smart outside-of-the-boot flick and the Costa Rica international fired past Ellery Balcombe with great composure.
Killian Phillips missed St Mirren's best chance before the interval with a header and, moments after the second half started, Hearts doubled their advantage through Oyegoke's magnificent attempt.
Balcombe was spared from embarrassment as his attempted clearance hit Spittal, and then cannoned back off himself and trundled towards an empty goal, recovering in the nick of time to clear.
Despite Hearts' dominance, St Mirren did fight their way back into the contest but were unable to fashion many goalscoring opportunities.
A late cross forced Craig Gordon to make a brave, low dive at Roland Idowu’s feet before Hearts doubled their tally with two late goals thanks to Wilson's tap-in and Spittal's curving effort.