Everything that DeSantis has done, especially lately has been his way of running for President. He feels like he needs to clip off some of the MAGA base by running further to the right, aka being more racist, homophobic, etc than everyone in the Republican primary in order to win the nomination. He'll be able to point to the legislation he signed, or the Executive Orders that he issued to show his credientals to the bigots in the Republican party.
The problem is, once Trump gets on debate stage and calls him Meatball Ron, pudding fingers or makes fun of him for getting his ass whopped by Mickey Mouse, its over for DeSantis.