It's a weaselly move by which Trump uses and plays our allies, who are now tasked to hold the line in the deal against Russian and Iran (Russia is part of the deal, but aims to enrich itself vias arms deals to Iran). They do all the work, because we said "just kidding!" and backed out, and we agitate Iran with sanctions, and point and cackle. The United States' credibility took a nosedive. Experienced Republicans knew this would happen, which is why they flipped their rhetoric with calls to stay in the deal, once shit got real.
It's hard to argue against observers who say it appears we are pining for war with Iran, as they now have impetus to cancel the deal and star refining fissile material again. I don't think that's the case, I think we are just a bull in a China shop, currently headed by a buffoonish child, but it's hard to argue against.