Amsterdam was chartered c.1300 and in 1369 joined the Hanseatic League. Having accepted the Reformation, the people in 1578 expelled the pro-Spanish magistrates and joined the independence-oriented Netherland provinces. The commercial decline of Antwerp and Ghent and a large influx of refugees from many nations (in particular of Flemish merchants, Jewish diamond cutters and merchants, and French Huguenots), contributed to the rapid growth of Amsterdam after the late 16th cent. The Peace of Westphalia (1648), by closing the Scheldt (Escaut) to navigation, further stimulated the city's growth at the expense of the Spanish Netherlands. Amsterdam reached its apex as an intellectual and artistic center in the 17th cent., when, because of its tolerant government, it became a center of liberal thought and book printing. The city was captured by the French in 1795 and became the capital of the Kingdom of the Netherlands, which was ruled by Louis Bonaparte. The constitution of 1814 made it the capital of the Netherlands; the sovereigns are usually sworn in at Amsterdam and reside in a palace outside the city. However, The Hague is the seat of government. During World War II Amsterdam was occupied by German troops (1940–45) and suffered severe hardship. Most of the city's Jews (c.75,000 in 1940) were deported and killed by the Germans. Since the 1960s Amsterdam has become known for political and social activism.