A more technical term for what you have described is dichotomous:
- dividing into two parts
- relating to, involving, or proceeding from dichotomy
Dichotomous thinking is associated with various mental disorders, from autism to borderline personality disorder, as well as with mood disorders such as depression and a whole range of eating disorders.
Commonly referred to as black and white thinking or all-or-nothing thinking, psychologists define it as splitting:
Splitting (also called black and white thinking or all-or-nothing thinking) is the failure in a person's thinking to bring together both positive and negative qualities of the self and others into a cohesive, realistic whole. It is a common defense mechanism used by many people.1 The individual tends to think in extremes (i.e., an individual's actions and motivations are all good or all bad with no middle ground). From wikipedia
Nowadays, popular criticism of dichotomous perspectives touches on everything from political affiliation and religious belief to gender identity and racial constructs.