No country since Japan in WW2 has declared war on the USA and US promises to protect South Korea and Taiwan have stopped North Korea and China taking over these countries
The USA spends 36 time more on its military than all other countries combined meaning countries like China and Russia are spending more and more to compete
Many countries are very willing to have US basses or military outposts in their country, though this might make them a target of someone who does not like the US it also means that they will gain protection from the USA which most countries want
The US has military bases on almost every continent (except Antarctica) because countries are willing to host them in return for gaining protection from the USAs huge military