Natural Inference for Primitives in Flow
This post announced natural inference for primitives when it was introduced. For current behavior, see the literal types and const expressions and const type parameters documentation.
Flow now decides the type of string, number, and boolean literal values at their definition site: either the broad type (e.g. string) or the literal type (e.g. 'foo'). You can control the behavior with type annotations, as const, or const type parameters.