Proposition 5
Tag 0BBR, permanent. Cite it as [Bourbaki, Tag 0BBR].
General Topology, chapter I, § 11. Connectedness
For a topological space to be not connected it is necessary and sufficient that there exists a surjective continuous mapping of onto a discrete space containing more than one point.
The condition is sufficient by Proposition 4. Conversely, if is not connected, there exist two non-empty disjoint open subsets whose union is , and the mapping of onto a discrete space of two elements , defined by and , is continuous.
Bourbaki puts the proof directly after the statement, so what is above is the statement and its proof together.