Slovenia gained its independence from Yugoslavia in June 1991, and is today a member of the European Union and NATO.Potok Cave in the Eastern Karawanks, where the remains of a human residence dated to the Aurignacian (40,000 to 30,000 BP) were found by Srečko Brodar in the 1920s and 1930s.Coming from two directions, North (via today's East Austria and Czech Republic), settling in the area of today's Carinthia and west Styria, and South (via today's Slavonia), settling in the area of today's central Slovenia.This Slavic tribe, also known as the Alpine Slavs, was submitted to Avar rule before joining the Slavic King Samo's tribal union in 623 AD.
The state of Slovenia was created in 1945 as part of federal Yugoslavia.
After Samo's death, the Slavs of Carniola (in present-day Slovenia) again fell to Avar rule, while the Slavs north of the Karavanke range (in present-day Austrian regions of Carinthia, Styria and East Tyrol) established the independent principality of Carantania.
In 745, Carantania and the rest of Slavic-populated territories of present-day Slovenia, being pressured by newly consolidated Avar power, submitted to Bavarian overrule and were, together with the Duchy of Bavaria, incorporated into the Carolingian Empire, while Carantanians and other Slavs living in present Slovenia converted to Christianity.
Rome finally abandoned the region at the end of the 4th century.
Most cities were destroyed, while the remaining local population moved to the highland areas, establishing fortified towns.