We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents 31e5a40 + 61c9902 commit edc3347Copy full SHA for edc3347
.changeset/nice-carrots-crash.md
@@ -0,0 +1,5 @@
1
+---
2
+'esrap': patch
3
4
+
5
+fix: only push `with` clause if attributes length is gt 0
src/handlers.js
@@ -1165,7 +1165,7 @@ const handlers = {
1165
1166
state.commands.push(' from ');
1167
handle(node.source, state);
1168
- if (node.attributes) {
+ if (node.attributes && node.attributes.length > 0) {
1169
state.commands.push(' with { ');
1170
for (let index = 0; index < node.attributes.length; index++) {
1171
const { key, value } = node.attributes[index];
0 commit comments