-
Notifications
You must be signed in to change notification settings - Fork 5
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
Greater and less than signs in attribute strings are converted to HTML entities. #4
Comments
I looks like all HTML entities are converted everywhere:
Is this a necessary limitation? Seems to be causing lots of problems for me, and I can't figure out a way around it. |
Okay, it looks like I can use backtick escaping to fix the second example (button.close |
Alright, after some further testing it appears that |
This is an interesting issue. Either we abandon automatic HTML escaping or we keep it (for single/double quotes, and backticks never escape). I'm not really sure what to do because I can see merits with both. It is a pain, when composing SIML, to escape my own content -- e.g. it's nice to be able to just type '&' for an ampersand instead of '&' but I can see your argument to. I'll have a think about this. Maybe there should be an additional escaping prefix/operator to force escaping, otherwise nothing is escaped. e.g. ( using minus operator, similar to underscore.js'
|
I like the idea of the special non-escaping prefix. However, since we already have a "raw string" operator with the backticks, could we not just enable something like this instead?
(Currently, the line above compiles to |
Ah, ok. I see the problem. You should indeed be able to use back-ticks within directives and attributes -- working on a fix now.. |
…parsed correctly (and left unescaped). Add tests too. Re: issue #4
Just pushed a fix and bumped version to 0.3.4. The |
Awesome! Thanks for your help! |
div @show("todos.length > 0")
compiles to<div ng-show="todos.length > 0"></div>
, which breaks Angular. Is there currently a way around this?The text was updated successfully, but these errors were encountered: