It's good policy. I could go into detail but the short version is we live on a single planet, what goes around comes around. Some people think the US can isolate itself and not worry about what the rest of the world does or thinks, but that is a dangerous delusion.
What ever assistance we provide others is paid back in other ways, just like being neighborly isn't mandatory but is a very good idea.