On [email protected]:
import type Foo from 'foo';
import type Foo2 from 'foo';
import type Foo3 from 'foo';
var a: {add(x:Foo, ...y:Array<Foo2>): Foo3}; a;
import add from 'lodash/add';
import type Foo from 'foo';
import type Foo2 from 'foo';
import type Foo3 from 'foo';
var a: { add: (x: Foo, ...y: Array<Foo2>) => Foo3 };a;
The add identifier inside of the Flow type annotation on line 4 is apparently being treated as a ReferencedIdentifier and therefore triggering the lodash import. This definitely shouldn't be the case.
I don't have a suggested resolution at the moment as I haven't been able to figure it out myself. This may actually be a Babel bug.
On
[email protected]:The
addidentifier inside of the Flow type annotation on line 4 is apparently being treated as aReferencedIdentifierand therefore triggering the lodash import. This definitely shouldn't be the case.I don't have a suggested resolution at the moment as I haven't been able to figure it out myself. This may actually be a Babel bug.