emblem.js
emblem.js copied to clipboard
hasBlock is true when it shouldn't be on new component syntax
This causes hasBlock to be true inside the avatar-image.{hbs|embl} when it should not be
%AvatarImage @url=this.session.currentUser.avatarCloudFile.downloadUrl @name=this.session.currentUser.name
= this.session.currentUser.shortName
If I use the older syntax, it seems to work
= avatar-image url=this.session.currentUser.avatarCloudFile.downloadUrl name=this.session.currentUser.name
= this.session.currentUser.shortName
This seems to be because angle bracket components are considered to have block if they have a closing tag. Emblem always produces:
<AvatarImage @url={{}} ... ></AvatarImage>
vs
<AvatarImage @url={{}} ... />
i am not that much of an expert of pegjs to be able to fix it quickly, looking at it, though.