Skip to content
This repository has been archived by the owner on Feb 19, 2022. It is now read-only.

babel-plugin-server: spread attributes #74

Open
shuhei opened this issue Apr 12, 2017 · 3 comments
Open

babel-plugin-server: spread attributes #74

shuhei opened this issue Apr 12, 2017 · 3 comments
Labels

Comments

@shuhei
Copy link

shuhei commented Apr 12, 2017

babel-plugin-server throws an error on spread attributes.

A minimum test case:

$ echo '<Foo {...props} />;' | ./node_modules/.bin/babel --plugins ./src/transform/server
TypeError: unknown: Cannot read property 'name' of undefined
    at objExpr.properties.forEach.property (/Users/shuhei/work/js/rapscallion/src/transform/server.js:198:21)
    at Array.forEach (native)
    at objectExpressionToObject (/Users/shuhei/work/js/rapscallion/src/transform/server.js:197:22)
    at PluginPass.exit (/Users/shuhei/work/js/rapscallion/src/transform/server.js:27:21)
    at newFn (/Users/shuhei/work/js/rapscallion/node_modules/babel-traverse/lib/visitors.js:276:21)
    at NodePath._call (/Users/shuhei/work/js/rapscallion/node_modules/babel-traverse/lib/path/context.js:76:18)
    at NodePath.call (/Users/shuhei/work/js/rapscallion/node_modules/babel-traverse/lib/path/context.js:48:17)
    at NodePath.visit (/Users/shuhei/work/js/rapscallion/node_modules/babel-traverse/lib/path/context.js:117:8)
    at TraversalContext.visitQueue (/Users/shuhei/work/js/rapscallion/node_modules/babel-traverse/lib/context.js:150:16)
    at TraversalContext.visitSingle (/Users/shuhei/work/js/rapscallion/node_modules/babel-traverse/lib/context.js:108:19)
@veiico
Copy link

veiico commented Jun 23, 2017

would be cool to have this feature working (having the same behavior)

@divmain
Copy link
Contributor

divmain commented Jun 30, 2017

Alright, this is next in my queue.

@divmain divmain added the bug label Jun 30, 2017
@dorian-marchal
Copy link

Any news on this ?

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

No branches or pull requests

4 participants