The last verse of chapter 12 (v.17) describes the future of the true Church, with the dragon continuing to make war with (to persecute) them so long as they uncompromisingly continue to follow the Word of God and maintain their testimony of faith alone in Jesus Christ.
In this chapter John describes his vision of a beast (v.1) that rises up out of the sea, which means out of the nations of peoples. It is the same beast described in v. 12:3 which was there described as the “great red dragon”. This seven-head beast (see below) represents the last 4 major empires of man.
The kings or emperors of those kingdoms are represented with “the name of blasphemy” written on them, meaning that they claimed god-like status, which we know was not uncommon among kings, for example, Nebuchadnezzar did with his golden image in Daniel 3 decreeing all to worshop his image; Artaxerxes is described as king of kings (Ezra 7:12), because he ruled over conquered kings, this led to a god-like status; Alexander the Great, who asserted that he was the son of Jupiter Ammon (Greek god); and the Roman Emperors, who all claimed divine status and required men to worship their statues and to offer them sacrifices.
On one head, Rome, it had 10 horns (v.1). The 10 horns represent the 10 kingdoms that pagan Rome was divided into but in v. 12:3 there were only 7 crowns, which are seen on the heads of the beast. But here the 10 horns each have crowns—there are 10 crowns—and those crowns are diadems (Greek διάδημα diadema). Diadems are worn by the kings. So this beast is different from pagan Rome. It has evolved from pagan Rome but it is more ‘wonderful’ and more dangerous. This must mean 3 additional kingdoms were added to this final kingdom (the beast) which I believe is an indication of papal Rome consolidating its power after the 4th century AD.