Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

macro call inside element throws error #7

Open
disnet opened this issue Aug 18, 2014 · 0 comments
Open

macro call inside element throws error #7

disnet opened this issue Aug 18, 2014 · 0 comments

Comments

@disnet
Copy link

disnet commented Aug 18, 2014

From the sweet.js mailing list. It seems like there's a problem with macros inside elements?

macro id {
    rule { $x } => { $x }
}

<h2>{id person.name}</h2>
// throws a parse error

Running sjs -p -l jsx-reader test.js gives:

_DOM {
  ( ( React . DOM ) . h2 ) null person . name ,
}

So it looks like the _DOM macro isn't being expanded for some reason.

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

No branches or pull requests

1 participant