Created
March 30, 2018 12:44
-
-
Save vramdal/462db673c22e56e4c5546990b9820cd2 to your computer and use it in GitHub Desktop.
Flow issue: Referencing this class as exported
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// @flow | |
import ClassB from "./ClassB"; | |
export default class ClassA { | |
constructor(objB : ClassB) { | |
} | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// @flow | |
import ClassA from "./ClassA"; | |
export default class ClassB { | |
func(objB : ClassB) : void { | |
let classA = new ClassA(objB); // Flow: Cannot call `ClassA` with `objB` bound to `objB` because `ClassB` [1] is incompatible with `ClassB` [2]. | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment