NEWARK, N.J. (AP) — After giving up 16 goals in the last three games, New York Islanders coach Barry Trotz saw a lot of more things he liked against the New Jersey Devils.

The Islanders competed, they didn’t have any letdowns after giving up goals and the coach got to see Mathew Barzal get a step ahead of the Devils’ defense in overtime.

Barzal scored on a his own rebound after being stopped on a breakaway at 3:40 of overtime and the Islanders beat the Devils 4-3 on Friday after giving up a late goal that allowed New Jersey to force the 3-on-3 overtime.

“There was more skin in the battle than we’ve had in the last couple games so I’ll take our game,” Trotz said. “New Jersey has been a very good team at home; they’ve been dynamite at home. I liked a lot of our game.”

The downer was seeing Marcus Johansson of the Devils batting his own rebound past Thomas Greiss (39 saves) with 11 seconds left in regulation.

While both teams had chances in the overtime, Barzal was the difference in sliding one past Keith Kinkaid, who had 31 saves.

“Would have been nice if we didn’t give them that point but we’ll take the extra one and move on from there,” Barzal said after scoring only his third goal.

Trotz was coy when asked about watching fleet-footed Barzal in overtime.

“It depends; with or without the puck,” the coach said. “With the puck when he has a step on a guy, you get pretty excited.”

Jordan Eberle, Anders Lee and Nick Leddy also scored to help the Islanders snap a two-game losing streak and beat the Devils for the second time this season.

Taylor Hall and Brian Boyle also scored for the Devils, who are 7-1-3 at home.

“I wish we had a different outcome but unfortunately we didn’t,” Johansson said. “It was good of us to battle back. We did not get the start we wanted today. It was a tough game for us. I don’t think we played the way we wanted to. Instead of coming out, we had to fight our way back into it. We did a good job of that. We needed and wanted the two points.”

Leddy had given the Islanders a 3-2 lead with his first goal of the season. It came after a highlight reel length-of-the-ice rush with 7:15 to play on which he put in his own rebound.

New Jersey tied it at 2 early in the third period when Boyle deflected Blake Coleman’s shot past Greiss. The forward was activated earlier in the day after missing five games with an upper-body injury.

The Islanders had taken leads of 1-0 and 2-1 as Eberle and Lee sandwiched goals around a Hall tally.

It wasn’t Josh’s Bailey’s day. The New York forward was stopped on two great chances in the first period and lost a goal in the second when the Devils won a challenge because Barzal was offside on a 3-on-2 odd-man rush.

Barzal made up for the mistake in overtime.

NOTES: The Devils squandered an early 1:52 two-man power play. ... New Jersey also activated D Sami Vatanen off injured reserve before the game. New Jersey assigned D Eric Gryba to Binghamton (AHL). F Joey Anderson (lower body) was placed on injured reserve. ... This was the Devils’ Hockey Fights Cancer game. Bennett Burgida, an 11-year-old cancer survivor from Englewood served as an honorary assistant coach for the day and dropped a ceremonial opening faceoff. ... Devils wore lavender jerseys in the pre-game warmup. Cancer survivor Samantha Dango sang the national anthem. ... Islanders F Cal Clutterbuck returned to the lineup after missing the last game with an illness.