How to properly reference flow-typed in custom type declarations?
Aperta
- Lingua principale
- Rust
- Stelle
- 22.3k
- Fork
- 1.9k
- Metriche di merge delle PR
- Nessuna PR unita negli ultimi 30g
Descrizione
Let's say I use `bunyan` npm package and there is `flow-typed` for it already (https://github.com/flowtype/flow-typed/blob/master/definitions/npm/bunyan_v1.x.x/flow_v0.21.x-/bunyan_v1.x.x.js).
What I'm trying to achieve now is this:
```
declare class Context {
userId: string;
logger: bunyan.Logger;
};
```
And `flow` is failing with the following error:
```
type-annotation `bunyan`. Could not resolve name
```
I'm not quite sure what's going on and how to make it happy. Thanks!
Guida per i contributori
Apri la guida per i contributori
Valutazione
Questa issue non è ancora stata valutata.