Skip to content

Conversation

@prauscher
Copy link
Contributor

closes #275

Trigger markdownx-classes on formset:added: Django will create a "template" for each inline and copy it every time the user selects to add a new form. Sadly during cloning the event listeners are not cloned (and would not know their targets), so this PR simply re-instanciates MarkdownX for these elements.

Note that as the form is cloned, the data-markdownx-init is already set.

@prauscher
Copy link
Contributor Author

I really hope you understand my idea here - these are the first lines of typescript in my life, so I'm more than happy to accept feedback. Also I guess the failing test seems unrelated to my code change, maybe something is broken in master?

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

markdownx.js should add event listener for formset:added

1 participant