-
Notifications
You must be signed in to change notification settings - Fork 669
Open
Labels
type:unverified bugA bug report that has not been verifiedA bug report that has not been verified
Description
Marko Version: 6.0.155
Details
I want to wrap a native tag with a custom tag, so that I can enforce certain things like CSS, but find that this increases the bundle size.
Expected Behavior
// my-a.marko
<a ...input/>
// parent.marko
<my-a href="#my-a"/>
<a href="direct-call"/>
Both syntax in the parent component result in the same output. Ie, no JS is emitted.
Actual Behavior
JS is emitted when wrapped in a custom component. If I rewrote the custom component as:
// my-a.marko
<a href=input.href>
<${input.content}/>
</a>
Then, I get the expected behaviour of no JS being emitted. But this syntax becomes tedious, especially compared to the first version.
Steps to Reproduce
See https://github.com/vwong/marko6-spread-optimisation. I've also included therein a partially optimised work-around.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
type:unverified bugA bug report that has not been verifiedA bug report that has not been verified
Type
Projects
Status
Todo