Yugoslavia entered the war on the Allied side after the invasion of Axis powers on 6 April 1941. The Royal Yugoslav Army was thoroughly defeated in less than two weeks and the country was occupied starting on 18 April. The Italian-backed Croatian fascist leader Ante Pavelić declared the Independent State of Croatia before the invasion was over. King Peter II and much of the Yugoslavian government had left the country. In the United Kingdom, they joined numerous other governments in exile from Nazi-occupied Europe. Beginning with the uprising in Herzegovina in June 1941, there was continuous anti-Axis resistance in Yugoslavia until the end of the war.