Not long ago, in a borough not so far away, David Lee was far and away the most popular basketball player in New York. Though he is only in his third season with the Warriors, what he left behind is hardly recognizable.

The playoff-starved Knicks are now contenders. Brooklyn has basketball.

Returning to New York for just the second time since leaving the Knicks, Lee displayed a game last night at Barclays Center that has remained a constant, putting up his 11th double-double of the season by going for 30 points and 15 rebounds in the Warriors’ 109-102 win over the Nets.

After putting up 20 points and 13 rebounds in the Warriors’ win over the Nets on Nov. 21, Lee closed out last night’s victory by scoring 13 points in the fourth quarter.

“I feel like I’m partially from here now after playing here for so long,” Lee said. “A year in New York is like 20 years it feels like sometimes, especially when you’re losing, but it was great to be back here. I was just trying to be aggressive on the glass and let the offense take care of itself.”

Lee, who was dealt in a sign-and-trade as an unrestricted free agent after spending his first five seasons with the Knicks, was practically unstoppable, grabbing seven offensive rebounds while toying with Andray Blatche and Kris Humphries with a series of shot fakes and spin moves to shoot 14-of-22 from the field.

With the game tied at 89, Lee emerged as the deciding factor, scoring six straight points to give the Warriors their biggest lead to that point with 6:37 remaining. He added a putback two minutes later and converted a three-point play on a difficult turnaround bank shot with 2:53 left to keep the lead at seven. His wide-open dunk with 36.6 seconds left clinched it.

“He was huge,” said Stephen Curry, who finished with 28 points. “We were getting beat on the glass the whole game, and for him to come out and finish as strong as he did, David scored a couple times and kept that lead where it was.”

Warriors coach Mark Jackson was succinct when describing his forward’s performance. Jackson has learned what New York already knew: “David Lee was spectacular.”