jazzband / django-tinymce

TinyMCE integration for Django
http://django-tinymce.readthedocs.org/
MIT License
1.29k stars 316 forks source link

TinyMCE tries to import plugins/paste/plugin.min.js #476

Closed DeD1rk closed 2 months ago

DeD1rk commented 2 months ago

Tinymce is trying to import the paste plugin that, since updating from 3.7.1 to 4.1.0, does not exist in this package.

image

When doing the same on my production application, it is therefore loading the old versionof that plugin (Version: 5.10.7), which causes copying and pasting to be buggy/impossible there.

On my local version (where it gets 404, not an old version), the copying and pasting is fine, but still, it shouldn't try to get a file that will 404.

DeD1rk commented 2 months ago

Something related is that the tinymce files don't seem to use django's ManifestFilesMixin, which:

claudep commented 2 months ago

Usage of ManifestFilesMixin is never forced by 3rd-party apps, you should set it up in your projects.

Indeed paste is no longer a plugin in TinyMCE 6, see https://www.tiny.cloud/docs/tinymce/6/6.0-release-notes-core-changes/#removed-or-deprecated-plugins-paste. You should remove it from your plugin list.

DeD1rk commented 2 months ago

@claudep I see, removing the plugin works to get rid of the 404. I hadn't seen that in the changelogs.

Regarding the ManifestFilesMixin, I have set it up in production. But only a few of the django-tinymce files are actually referenced by the hashed urls (see also #266). Any files referenced from tinymce.min.js use the plain url. Using the cache_suffix config works, but something more automatic would be really nice.