What is different about ckeditor 5 compared to ckeditor 4?



Yüklə 208,53 Kb.
səhifə1/6
tarix26.10.2023
ölçüsü208,53 Kb.
#161566
  1   2   3   4   5   6
CKEditor 5


CKEditor 5.
CKEditor 5 provides every type of WYSIWYG editing solution imaginable. Users can manage media and tables as well as advanced features with ease because of the editor's well-designed UI and perfect UX.
What is different about CKEditor 5 compared to CKEditor 4?

Read more from here
Demo.
Check the Ckeditor5 demo from here to see how it is different from Ckeditor4.
Implementation of CKEditor5 in Django.
It is a demo video (video of end result).
We can implement the ckeditor5 in Django using django-ckeditor-5.
Installation.
pip install django-ckeditor-5
1. Add django_ckeditor_5 in your INSTALLED_APPS in your project/settings.py
# settings.py

INSTALLED_APPS = [


....
'django_ckeditor_5',
]
2. Also, add static and media file settings in your project/settings.py
# settings.py

STATIC_URL = '/static/'


MEDIA_URL = '/media/'
MEDIA_ROOT = BASE_DIR / 'media'
STATIC_ROOT = BASE_DIR / 'static'
3. Now run collectstatic command
python manage.py collectstatic
4. Include the ckeditor5 URL in your mainproject/urls.py file
# mainproject/urls.py

from django.contrib import admin
from django.urls import path, include
from django.conf import settings
from django.conf.urls.static import static

urlpatterns = [


path('admin/', admin.site.urls),
path("ckeditor5/", include('django_ckeditor_5.urls')),
] + static(settings.MEDIA_URL, document_root=settings.MEDIA_ROOT)

if settings.DEBUG:
urlpatterns+=static(settings.STATIC_URL, document_root=settings.STATIC_ROOT)
urlpatterns += static(settings.MEDIA_URL, document_root=settings.MEDIA_ROOT)
5. Add model to your app/models.py
# models.py


Yüklə 208,53 Kb.

Dostları ilə paylaş:
  1   2   3   4   5   6




Verilənlər bazası müəlliflik hüququ ilə müdafiə olunur ©www.azkurs.org 2024
rəhbərliyinə müraciət

gir | qeydiyyatdan keç
    Ana səhifə


yükləyin