J., first take a deep breath and realize that this was one day, not every day -- you said yourself that until today, your daughter stops when told to and apologizes. At age 2, that's great.
As for today: You said three key words: "She just laughed." She kept hitting, and laughing, because she was getting reactions from you--even yelling at her is still attention, even if it's negative attention.
If this repeated hitting happens again -- and it's a lot less likely to if she gets her naps, as I can tell you know already -- just don't react other than to tell her no, we never hit, you must have time out, and place her in time out for two minutes (one minute per year of age), somewhere safe for her but away from you, where she can't get to you. No talking it through first, no "this makes me feel...", no yelling. She hits, she gets isolated from you immediately, no time in between action and consequence after the first warning. When her time's up, she apologizes. But another hit means instant return to time out, no discussion. It sounds like whatever time outs you used today somehow became part of the game to her; I might put her somewhere safe where she can see you and vice versa that has a baby gate between you. Then you carry on with quiet housework or just sitting and reading, where you can see her but she still must stay put. If she says sorry but then hits again, right back to her time out area she goes. Every single time even if it takes a dozen times. If you ever watch "Supernanny" this is how she operates -- repeated, firm but calm time outs, consistently, even if it takes hours at a time, and sometimes on that show it does take dozens of returns to time out to stop a behavior. This might be too tough for her -- This tends to get used for cases of repeated behavior and it sounds like your toddler might have just been fried from tiredness this one day. But the idea is ensuring it doesn't become a game and she doesn't get rewarded with your attention, even in the form of yelling.