-
Notifications
You must be signed in to change notification settings - Fork 24.8k
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
EOF error when using svg:title tag in component template #31503
Comments
Seems like this issue belongs to the angular/angular monorepo // cc @alan-agius4 |
Angular tokenizer takes into account only
The
So for |
Is there any workaround? |
I've searched a lot to get a workaround, but it simply seems to be not possible currently. I've had to comment out those elements in our product to get the compiler work again |
Hello,
Thanks alexzuza for the help of finding the code change. |
…le tag The parser has a list of tag definitions that it uses when parsing the template. Each tag has a `contentType` which tells the parser what kind of content the tag should contain. The problem is that the browser has two separate `title` tags (`HTMLTitleElement` and `SVGTitleElement`) and each of them has to have a different `contentType`, otherwise the parser will throw an error further down the pipeline. These changes update the tag definitions so that each tag name can have multiple content types associated with it and the correct one can be returned based on the element's prefix. Fixes angular#31503.
…le tag The parser has a list of tag definitions that it uses when parsing the template. Each tag has a `contentType` which tells the parser what kind of content the tag should contain. The problem is that the browser has two separate `title` tags (`HTMLTitleElement` and `SVGTitleElement`) and each of them has to have a different `contentType`, otherwise the parser will throw an error further down the pipeline. These changes update the tag definitions so that each tag name can have multiple content types associated with it and the correct one can be returned based on the element's prefix. Fixes angular#31503.
…le tag The parser has a list of tag definitions that it uses when parsing the template. Each tag has a `contentType` which tells the parser what kind of content the tag should contain. The problem is that the browser has two separate `title` tags (`HTMLTitleElement` and `SVGTitleElement`) and each of them has to have a different `contentType`, otherwise the parser will throw an error further down the pipeline. These changes update the tag definitions so that each tag name can have multiple content types associated with it and the correct one can be returned based on the element's prefix. Fixes angular#31503.
…le tag (#40259) The parser has a list of tag definitions that it uses when parsing the template. Each tag has a `contentType` which tells the parser what kind of content the tag should contain. The problem is that the browser has two separate `title` tags (`HTMLTitleElement` and `SVGTitleElement`) and each of them has to have a different `contentType`, otherwise the parser will throw an error further down the pipeline. These changes update the tag definitions so that each tag name can have multiple content types associated with it and the correct one can be returned based on the element's prefix. Fixes #31503. PR Close #40259
This issue has been automatically locked due to inactivity. Read more about our automatic conversation locking policy. This action has been performed automatically by a bot. |
🐞 Bug report
Command
Is this a regression?
Yes, the previous version in which this bug was not present was: 7.x.x
Description
Using the svg title tag in a different component (using the namespace like svg:title) than the svg root tag component will cause a template parse error. (using title inside a component with svg root tag works fine)
This is working fine:
While this isn't working:
🔬 Minimal Reproduction
I've prepared a working example of this issue on stackblitz:
https://stackblitz.com/edit/angular-rqi6k5
🔥 Exception or Error
🌍 Your Environment
Anything else relevant?
The text was updated successfully, but these errors were encountered: