-
Notifications
You must be signed in to change notification settings - Fork 21
Closed
Description
Hi, I'm trying to switch from transform-async-to-module-method
to fast-async
, and I bumped into this error. I reduced the code to this minimal example:
test.js:
export const A = '';
class B {
async f() {
await g();
}
}
.babelrc:
{
"presets": [
"es2015",
"stage-0"
],
"plugins": [
["fast-async", {
"runtimePattern": "main.js"
}],
]
}
And it produces the following error:
Error: test.js: Cannot append Element node to non-array
at Object.append (/home/diego/repos/brainiac-www/node_modules/nodent/lib/parser.js:87:23)
at /home/diego/repos/brainiac-www/node_modules/nodent/lib/arboriculture.js:2190:34
at Array.forEach (native)
at /home/diego/repos/brainiac-www/node_modules/nodent/lib/arboriculture.js:2189:32
at Object.treeWalker (/home/diego/repos/brainiac-www/node_modules/nodent/lib/parser.js:156:5)
at hoistDeclarations (/home/diego/repos/brainiac-www/node_modules/nodent/lib/arboriculture.js:2136:16)
at asyncTransforms (/home/diego/repos/brainiac-www/node_modules/nodent/lib/arboriculture.js:359:9)
at asynchronize (/home/diego/repos/brainiac-www/node_modules/nodent/lib/arboriculture.js:352:9)
at NodentCompiler.asynchronize (/home/diego/repos/brainiac-www/node_modules/nodent/lib/arboriculture.js:2657:20)
at PluginPass.Program (/home/diego/repos/brainiac-www/node_modules/fast-async/plugin.js:36:14)
Is this a bug in fast-async
, or perhaps something wrong in my code?
Thanks!
pawelrychlik
Metadata
Metadata
Assignees
Labels
No labels