Top "Flowtype" questions

Flow is a static type checker, designed to find type errors in JavaScript programs, created by Facebook.

ESLint with Arbnb config and Facebook Flow together

I am using ESLint in a project and want to use Facebook flow as well, But I am getting warnings …

javascript facebook reactjs eslint flowtype
Ignoring node_modules when using flow

I am using flow within my React Native application, the initial startup of flow is incredibly slow because it is …

flowtype
flow type question mark before or after param?

Can someone explain the difference between: function foo(bar: ?string) { console.log(bar); } and: function foo(bar?: string) { console.log(…

javascript ecmascript-6 flowtype
ES6 Map in Flowtype

What is the appropriate way to deal with ecmascript-6 Map objects in flowtype? const animals:Map<id, Animal> = …

javascript ecmascript-6 flowtype
Flow type for optional field in an object

In the following code (Try Flow): type Response = { err: ?string; data: Object; } function length(x): Response { return { data : {} }; } length(10) I …

javascript flowtype
Dynamic property names in flow typed object

I'm slowly and surely working flowType into my code, but I'm struggling with one concept. How do I specify the …

javascript syntax flowtype
How to do flow type annotations for React hooks (useState, etc.)?

How should we be using Flow type annotations with react hooks, such as useState? I've tried searching for some examples …

reactjs flowtype
how to define ref type by flowtype?

I trying to define type of ref by flowtype in react v16.4.0 But I couldn't resolve it, so please let …

reactjs flowtype ref
Flowtype, React and defaultProps

After hours of searchs and tests, I didn't succeed to find any solution to make flow understand defaultProps See Try …

reactjs react-native flowtype
Is there a point to doing 'import type' rather than 'import' with Flow?

Flow allows you to use the following syntax to import types: // SomeClass.js export default class SomeClass {} // SomeFile.js import …

javascript ecmascript-6 flowtype commonjs