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

Turn attrs into an object #38

Closed
nippur72 opened this issue Dec 10, 2015 · 4 comments
Closed

Turn attrs into an object #38

nippur72 opened this issue Dec 10, 2015 · 4 comments

Comments

@nippur72
Copy link
Contributor

When a tag is compiled, attrs are stored as a plain string and later at runtime they are processed with the walkAttributes function (during the mount event).

I suggest to move attribute parsing into compiler, outputting attributes as a plain javascript object (key-value pairs) so it's easier and faster to process them at runtime.

@aMarCruz
Copy link
Contributor

@nippur72 , you are right and I have it in my TODO for the next version. It is one reason for riot.tag2, avoiding breaking change.

@aMarCruz
Copy link
Contributor

maybe in v2.4, which also will include the remotion of __ for boolean attributes. I need write code to handle these changes in riot.tag transparently.

@GianlucaGuarini
Copy link
Member

I also would love to see this feature landing in riot@3.0.0

@GianlucaGuarini
Copy link
Member

the attributes can be spreaded with v4.0.0. <p ...{attributes}>. I am closing this issue

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