pugjs / babel-plugin-transform-react-pug

A plugin for transpiling pug templates to jsx

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

prop spreading (support attribute blocks)

p-98 opened this issue · comments

commented

I am trying to translate jsx with prop spreading to pug

<div {...attributes} />

The only possibility I was able to come up with was

div&attributes(attributes)

Unfortunately this currently throws Attribute blocks are not yet supported in react-pug.

It would be awesome to see this feature supported. Or is there any other solution?

commented

@ezhlobo thanks for the clue. Seems like I missed it.

Since this syntax makes attribute blocks obsolete, I will close this issue.