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

angular2 bindings/attributes #422

Closed
fxck opened this issue Oct 21, 2015 · 3 comments
Closed

angular2 bindings/attributes #422

fxck opened this issue Oct 21, 2015 · 3 comments

Comments

@fxck
Copy link

fxck commented Oct 21, 2015

There's alot of stuff like this <a [router-link]="['/Index']">Index</a> or even ([some-thing])="asdf" in angular2, and the minifier doesn't seem be to able to handle those..

image

.. and yes, it is valid html.

@kangax
Copy link
Owner

kangax commented Oct 24, 2015

You can use customAttrSurround for this — https://github.com/kangax/html-minifier/blob/gh-pages/tests/minifier.js#L521-L537

@kangax kangax closed this as completed Oct 24, 2015
@fxck
Copy link
Author

fxck commented Oct 24, 2015

Amazing thanks, but still, these are all valid attributes, it could by "on" by default.

@david-gang
Copy link

Update: I missed #289

Hi @kangax

I agree with @fxck
Angular 2 will be a very popular framework.
Additionally according to http://stackoverflow.com/a/30863873/2343743 these attributes are valid.

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

3 participants