Skip to content

Conversation

DanBurton
Copy link

Related to #71. Support for spread expressions was added for all contexts other than object literals. This PR adds support for them in object literals, too.

quintenkasteel added a commit that referenced this pull request Sep 7, 2025
Add JSObjectSpread constructor to JSObjectProperty type and implement
grammar rules to parse spread expressions in object literals.

- Add JSObjectSpread constructor with annotation and expression fields
- Update ShowStripped instance for JSObjectProperty to handle spreads
- Add SpreadExpression support to PropertyAssignment grammar rule
- Add spreadExpressionToProperty helper function for AST conversion

Enables parsing of object spread syntax like {...obj} according to
ECMAScript specification for object literal spread expressions.

Resolves: Object spread syntax parsing for PR #118
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 this pull request may close these issues.

2 participants