What is the idea of implementing the 'preview' function when publishing an article in the cms background? How do you implement it? What is the idea of implementing the 'preview' function when publishing an article in the cms background, how can we implement and communicate with each other?
Reply content:
What is the idea of implementing the 'preview' function when publishing an article in the cms background? How can we implement and communicate with each other?
Some rich text editors provide the preview function, but in fact this preview is very different from the foreground effect, and some open-source products provide better and more realistic implementations, such as wordpress and durpal.
The reason for the wide-Text Editor's preview deviation is the css setting. At the same time, we can see that these better and more authentic open-source products can find a common feature, that is, the draft function, therefore, we can think of such an idea.
The document needs to be saved before previewing to make it a "persistent" data, and then load the front-end css in a specific container (such as iframe, then, the content of the article is displayed to see the final effect of the article displayed on the front end.
Although it is easy to say, it is not easy to do, and too many details need to be processed.