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

Support for tags other than script #107

Closed
mmajchrzak opened this issue Oct 18, 2016 · 1 comment
Closed

Support for tags other than script #107

mmajchrzak opened this issue Oct 18, 2016 · 1 comment

Comments

@mmajchrzak
Copy link
Contributor

Currently, when a developer creates a dynamic snippet it must be surrounded by:
<script data-api-type="templating" [...]>[...]</script>. While in most cases this is super fine, there are cases where this limitation may be problematic. For instance, the repository interprets script tags on its own or changes its behaviour upon script tags (real cases: AEM Link Transformer does not working; HTL conflicts).
Knot.x should not rely on tag names but rather on their attributes - it should be enough to check if data-api-type="templating" on any element exists, and if so then interprets such an element as snippet root.

@marcinczeczko
Copy link
Contributor

Relying on just tag attributes to discover Knot.x snippet is kind of cumbersome due to the way how Knot.x process HTML itself.
However, what if we introduced custom HTML tag, for instance or - anything that's not in HTML spec.
The question is if those mechanism you're referring are capable of parsing such tags ? especially to modify theirs attributes (by mentioned link transformer) ?

Answer on this would give help us to decide in what direction we should go.

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

No branches or pull requests

2 participants