当前位置:网站首页>Flask blog practice - integrated rich text editor quill
Flask blog practice - integrated rich text editor quill
2022-06-22 08:31:00 【Light programming】
Rich text editor Quill
Why do I need to integrate rich text editors ?
What is the main function of a blog , That's writing , If we can't make typography and beautification of the content we publish , So what's the meaning of what we publish ? It is also very unfriendly and disrespectful to readers , A well - arranged article is often pleasing to the eye , It will also make readers love your blog , So the use of rich text editor is very important !
Why choose a rich text editor Quill?
You may have questions , Why do so many rich text editors in the market choose it , First of all Quill Rich text editor is an open source editor , It's in GitHub Upper star Top of the list . Experience it , Its advantage is light weight 、 Strong compatibility 、 The supported plug-in extensions are rich , If you need any additional functions, just introduce them separately .
Besides , It also applies to Vue and React The packaged version of , No matter which front-end framework you are used to , Can use it without difference .
Integrate Quill
Integrate Quill The idea is to display a blank rich text editor when adding a new article , And assign the contents of the editor to the form synchronously , When editing an article, you must echo the content to the rich text editor and modify the form content synchronously !
stay app/admin/templates/admin/article_form.html New form element in
Introduce the style of rich text editor css And for asynchronous submission axios.js
{% block extra_head_style %}
<link href="https://cdn.quilljs.com/1.3.6/quill.snow.css" rel="stylesheet">
<script src="https://unpkg.com/axios/dist/axios.min.js"></script>
{% end边栏推荐
猜你喜欢

每周推荐短视频:什么是“计算世界”?

13 代理模式

Email giant exposes serious vulnerability, user data is stolen

08 桥接模式

一文彻底搞懂My SQL索引知识点

Mysql5.6.36 tutorial

Record once · fluent file buffer

Application of complex science in Maker Teaching Research

Learn data warehouse together - Zero

Analyzing the role of cognitive theory in maker teacher training
随机推荐
Matplotlib | temperature change visualization
Chapter II exercise | MNIST dataset | Titanic dataset | image enhancement
17 迭代器模式
11 外观模式
Daily learning-01
C # read / write TXT file to listview
One hot and embedding
HashTable源码解析、Collections.synchronizedMap解析
Basic knowledge and practical application of redis
Basic concepts of homomorphic encryption
13 proxy mode
[conda]conda切换为中科大源
08 桥接模式
Basic operation knowledge of DML and DQL
C # realizes voice reading function
中断中为何不能使用信号量,中断上下文为何不能睡眠
Detailed explanation of the underlying principle of concurrent thread pool and source code analysis
Three characteristics of concurrency 2-orderliness
Several methods to prevent repeated form submission + actual measurement
Store the numbers in the array in reverse order