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

Implement serde::Serialize on AST #143

Closed
lucacasonato opened this issue Apr 6, 2022 · 4 comments · Fixed by #176
Closed

Implement serde::Serialize on AST #143

lucacasonato opened this issue Apr 6, 2022 · 4 comments · Fixed by #176

Comments

@lucacasonato
Copy link
Contributor

This would be very useful for the CSSOM implementation in Deno (also see #5). Many cssparser structs already have serde::Serialize implementations when you enable the serde feature for cssparser.

If the binary size increase is too much, we can flag it with a crate feature.

I'll try to open a PR later this week.

@johno
Copy link

johno commented Apr 27, 2022

Somewhat relatedly, it'd be great if the properties themselves implement serde::Serialize. For my use case I want to run the parser on property values and get that data back via napi in node.

Is this a feature that folks would accept in this project? If not, is there a recommended way to serialize this data without (hopefully) having to implement Property and all its variants?

@devongovett
Copy link
Member

Yep, serde support would be great!

@devongovett
Copy link
Member

Assuming you didn't start this @lucacasonato. If not I can probably do it this weekend.

@lucacasonato
Copy link
Contributor Author

@devongovett I did start on this actually - I won't be able to push it up until Tuesday unfortunately though (the branch is on a different device).

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

Successfully merging a pull request may close this issue.

3 participants