Danny Espinosa salutes the crowd at Nationals Park after his grand slam Sunday against the Reds. (John McDonnell/The Washington Post)

In the first game he played at Nationals Park in September 2010, Danny Espinosa went 4 for 5 with two home runs and six RBI. Just up from the minors, he got a curtain call. A star born?

Then came six years of, mostly, baseball hell. Espinosa was switched from shortstop to second base, played productively there for two seasons, then had a total career meltdown. The precise baseball phrase is that “the game ate him alive.” For two years. He was sent to the minors and ordered to stop being a switch hitter, to bat only right-handed, because he looked so hopeless left-handed. Even as a useful utility man, he was a convenient target of boos, groans and mockery from Washington Nationals fans.

His “strikeout average” (.274) was higher than his batting average (.230). His exceptional defensive gifts were overlooked and his play-hurt durability was ignored while his hitting flaws became a symbol of team futility. His career and his confidence were shredded, year after year, by a relentlessly vicious game that exposes you in public and weakens you psychologically, then attacks the exact same spot the next day and the next for what feels like forever, until you wonder whether you were ever any good in the first place. Through it all, a much-humbled Espinosa, always searching for answers, persevered.

Baseball wants to beat you down, then drive you out, give your place to someone else. The game makes you an offer you can’t refuse — or so it seems: quit the game or else be broken in some deeply interior part of yourself and in a way that you may never learn to repair. But Espinosa refused the offer.

On Sunday at Nationals Park, Espinosa again went 4 for 5 with two home runs — one right-handed and one left-handed — and six RBI. He again got a standing ovation and a curtain call.

The applause Espinosa heard six years ago was an ovation for youth and hope. The cheers he heard Sunday — and it was the third time in four days that he has been pulled out of the dugout for a standing ovation — were an entirely different type. They were cheers of respect, commiseration and identification. The Danny of 2010 was a kid with gifts we couldn’t imagine possessing. The Espinosa of Sunday was an adult who had fought for his place in the game he loved for years and — for now, at least, until the game’s next assault — can look at himself with something close to wonderment.

Sunday’s amazing performance in a 12-1 Nationals romp, including a jewel of a play in the shortstop hole to rob a hit, merely culminated what has been an almost unbelievable four days for Espinosa against the Reds — with five home runs and 15 RBI. Those four games cap an incredible five weeks in which he has hit 15 home runs and driven in 33 runs in just 35 games while playing a brilliant, mistake-free shortstop.

“Feel great. It’s surreal. It’s crazy. I’m just out there having fun. I’m just staying with my work every day, and it’s paying off,” Espinosa said. “I couldn’t dream anything like this could ever happen. It doesn’t feel real.”

Espinosa leads the Nationals with . . . excuse me, they’re coming so fast I’m losing count . . . 18 homers. Bryce Harper has 17. Poor Mike Trout — send the Angels superstar a get-well card — also has 17.

“No. I never thought that I’d be there,” Espinosa said of being the No. 1 home run man on the No. 1 home run team in the National League. “I’m just staying who I am and not going to go crazy. Just enjoy it. Things don’t last forever, and I’m going to enjoy the moment that I’m in right now.”

This moment has him tied for second in homers among all shortstops, sixth in RBI (49) and eighth in on-base-plus-slugging (.820), and he has done all of it while usually batting eighth with no protection behind him.

No, it’s not going to last. Are you kidding? This wouldn’t last for Babe Ruth.

This moment requires context. Espinosa arrived as a hot-shot shortstop out of a Long Beach State program that had produced stars Troy Tulowitzki and Evan Longoria. Danny expected to become a star. Not out of vanity, though he had some. He just believed what he was told. Danny, you’re as good as we are.

In the six years since, perhaps the cruelest twist was that he played a position he excelled at but which, emotionally, he only tolerated. “If you can’t be with the one you love, love the one you’re with,” the song says. So he loved second base. He watched Ian Desmond, who had seniority and was a good friend, play shortstop with flair but also with 24 errors a year. Finally, this season, after Desmond left as a free agent, Manager Dusty Baker told Espinosa, “You’re my everyday shortstop.”

“I’m home. I’m a shortstop,” Espinosa told me in spring training. “It’ll improve every part of my game.”

On Sunday, he added: “Every day, I love it at shortstop [because] I’m not thinking about hitting. I just want to play great defense for the team.”

No sooner was Espinosa the shortstop of the present than Trea Turner, acquired in a trade before 2015, was anointed the Shortstop of the Future. Every week, Nats fans counted down to the Turner debut and the removal to a utility role of the too-familiar Espinosa. At 29, how could Danny get better?

By May 25, Espinosa was hitting .199. On June 3, because of injuries, Turner was called up. He went 3 for 3 with a walk . But perhaps in a flight-or-fight response to Turner’s imminent threat, Espinosa hit four homers in the week before Turner came up. Was this the player the Nats hoped they would see?

Baker and General Manager Mike Rizzo stuck with Espinosa. The team was winning. And the defense suddenly made the fewest errors in baseball. Second baseman Daniel Murphy, acquired for his bat, seemed a much better fielder with Espinosa beside him. How much of this better, calmer and more confident defense flowed out from Espinosa’s glove-man swagger? Why change now?

Turner was sent back down. And Espinosa, like a man released from prison — or perhaps a man who escapes from jail and doesn’t know how long he has before he’s caught and dragged back to his cell — has hit and slugged and fielded like a maniac. Baker’s only worry is that Espinosa will work too hard.

“He’s here so early, I have to tell him, ‘Go home,’ ” Baker said.

“I know I can grind myself into the ground sometimes. But this is what I love to do,” Espinosa said. “I dreamed about this as a kid my whole life, and I’m not going to let this opportunity pass me.”

Danny’s home — at shortstop. As an athlete, he is finally himself. Try to move him. It may be tough.

For more by Thomas Boswell, visit washingtonpost.com/boswell.