Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

WIP: Refactor patterns so all logic goes outside the templates #1315

Draft
wants to merge 1 commit into
base: 5.0.x
Choose a base branch
from

Conversation

frapell
Copy link
Member

@frapell frapell commented Apr 27, 2023

This PR is a work in progress for gh-1306

The base idea is that .template() from underscore needs to be replaced, and so all logic from the templates need to be stripped out.

Patterns that need to be refactored:

  • relateditems
  • contentloader
  • tinymce's link plugin
  • livesearch
  • upload
  • recurrence
  • structure
  • modal

When templates do not have logic in them, it should be enough to simply replace _.template() with utils.template() and that's it, but if the template does have logic, or any JS evaluation, then it needs some refactoring

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Mockup requires unsafe-eval for script-src rule when configuring CSP header
1 participant